/* Margonem Addon — motyw ciemny */
:root {
  --bg: #07090e;
  --bg-soft: #0c1018;
  --panel: #11161f;
  --panel-2: #151b26;
  --line: #1f2733;
  --line-soft: #19202b;
  --text: #e8edf4;
  --muted: #8a97a8;
  --muted-2: #5d6878;
  --accent: #2ce592;
  --accent-press: #21c97d;
  --accent-ink: #04130c;
  --blue: #5b9dff;
  --danger: #ff5470;
  --warn: #ffc24b;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 24px 60px -20px rgba(0,0,0,.7);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(1100px 600px at 78% -10%, rgba(44,229,146,.10), transparent 60%),
    radial-gradient(900px 500px at 8% 0%, rgba(91,157,255,.07), transparent 55%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
}
a { color: inherit; text-decoration: none; }
::selection { background: rgba(44,229,146,.28); }

/* ---------- layout ---------- */
.container { max-width: 1080px; margin: 0 auto; padding: 0 22px; }
.section { padding: 84px 0; }
.muted { color: var(--muted); }
.center { text-align: center; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(7,9,14,.72);
  border-bottom: 1px solid var(--line-soft);
}
.nav .container { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: -.2px; }
.brand .dot { width: 12px; height: 12px; border-radius: 4px; background: var(--accent); box-shadow: 0 0 18px rgba(44,229,146,.8); }
.nav-links { display: flex; gap: 8px; align-items: center; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 650; font-size: 14px;
  padding: 11px 18px; border-radius: var(--radius-sm); border: 1px solid transparent;
  cursor: pointer; transition: .16s ease; white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent-press); box-shadow: 0 8px 24px -8px rgba(44,229,146,.6); }
.btn-ghost { background: rgba(255,255,255,.04); color: var(--text); border-color: var(--line); }
.btn-ghost:hover { background: rgba(255,255,255,.08); border-color: #2b3645; }
.btn-danger { background: rgba(255,84,112,.12); color: #ff8298; border-color: rgba(255,84,112,.3); }
.btn-danger:hover { background: rgba(255,84,112,.2); }
.btn-sm { padding: 8px 13px; font-size: 13px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* ---------- hero ---------- */
.hero { padding: 92px 0 64px; position: relative; }
.hero-grid {
  position: absolute; inset: 0; z-index: -1; opacity: .35;
  background-image: linear-gradient(var(--line-soft) 1px, transparent 1px),
                    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(680px 380px at 50% 8%, #000 30%, transparent 75%);
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12.5px; font-weight: 600; letter-spacing: .3px;
  color: var(--accent); background: rgba(44,229,146,.08);
  border: 1px solid rgba(44,229,146,.22); padding: 6px 13px; border-radius: 999px;
}
.hero h1 {
  font-size: clamp(34px, 6vw, 58px); line-height: 1.04; margin: 22px 0 16px;
  letter-spacing: -1.4px; font-weight: 820;
}
.hero h1 .grad { background: linear-gradient(100deg, var(--accent), #7af0c0 60%, var(--blue)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 18.5px; color: var(--muted); max-width: 640px; margin: 0 auto 30px; }
.hero .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ---------- cards / features ---------- */
.grid { display: grid; gap: 16px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 860px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 22px;
  position: relative;
}
.card.hov { transition: .18s ease; }
.card.hov:hover { border-color: #2c3a4a; transform: translateY(-2px); }
.feature .ic {
  width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center;
  background: rgba(44,229,146,.1); border: 1px solid rgba(44,229,146,.2); margin-bottom: 14px;
  color: var(--accent);
}
.feature h3 { margin: 0 0 6px; font-size: 16px; letter-spacing: -.2px; }
.feature p { margin: 0; color: var(--muted); font-size: 14px; }

.section-head { text-align: center; margin-bottom: 40px; }
.section-head h2 { font-size: clamp(26px, 4vw, 36px); letter-spacing: -.8px; margin: 0 0 10px; }
.section-head p { color: var(--muted); margin: 0; }

/* ---------- pricing ---------- */
.price-card { max-width: 380px; margin: 0 auto; text-align: center; }
.price-card .amount { font-size: 44px; font-weight: 820; letter-spacing: -1px; margin: 6px 0; }
.price-card .amount span { font-size: 16px; color: var(--muted); font-weight: 500; }
.price-list { list-style: none; padding: 0; margin: 18px 0 22px; text-align: left; }
.price-list li { padding: 7px 0; color: var(--muted); display: flex; gap: 10px; align-items: center; }
.price-list li::before { content: ""; width: 16px; height: 16px; border-radius: 5px; background: rgba(44,229,146,.16); border: 1px solid rgba(44,229,146,.4); flex: 0 0 auto; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line-soft); padding: 34px 0; color: var(--muted-2); font-size: 13px; text-align: center; }

/* ---------- auth ---------- */
.auth-wrap { min-height: calc(100vh - 64px); display: grid; place-items: center; padding: 40px 22px; }
.auth { width: 100%; max-width: 400px; }
.auth h1 { font-size: 24px; letter-spacing: -.5px; margin: 0 0 4px; }
.auth .sub { color: var(--muted); margin: 0 0 22px; font-size: 14px; }
.tabs { display: flex; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 10px; padding: 4px; margin-bottom: 18px; }
.tabs button { flex: 1; background: transparent; border: 0; color: var(--muted); font: inherit; font-weight: 600; padding: 9px; border-radius: 7px; cursor: pointer; transition: .15s; }
.tabs button.active { background: rgba(255,255,255,.06); color: var(--text); }

label.field { display: block; margin-bottom: 14px; }
label.field span { display: block; font-size: 12.5px; color: var(--muted); margin-bottom: 6px; font-weight: 500; }
.input {
  width: 100%; background: var(--bg-soft); border: 1px solid var(--line); color: var(--text);
  border-radius: var(--radius-sm); padding: 11px 13px; font: inherit; outline: none; transition: .15s;
}
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(44,229,146,.13); }

/* ---------- dashboard ---------- */
.topbar { display: flex; align-items: center; justify-content: space-between; padding: 18px 0; border-bottom: 1px solid var(--line-soft); margin-bottom: 28px; }
.topbar .who { display: flex; align-items: center; gap: 12px; }
.avatar { width: 38px; height: 38px; border-radius: 11px; background: linear-gradient(135deg, var(--accent), var(--blue)); display: grid; place-items: center; font-weight: 800; color: var(--accent-ink); }

.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.badge .sdot { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.badge.ok { color: var(--accent); border-color: rgba(44,229,146,.3); background: rgba(44,229,146,.08); }
.badge.ok .sdot { background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.badge.warn { color: var(--warn); border-color: rgba(255,194,75,.3); background: rgba(255,194,75,.08); }
.badge.warn .sdot { background: var(--warn); }
.badge.off { color: var(--danger); border-color: rgba(255,84,112,.3); }
.badge.off .sdot { background: var(--danger); }

.lic-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.keyline { display: flex; align-items: center; gap: 10px; }
.keyval { font-family: var(--mono); font-size: 15px; background: var(--bg-soft); border: 1px solid var(--line); padding: 8px 12px; border-radius: 8px; letter-spacing: .5px; }
.copy { background: rgba(255,255,255,.04); border: 1px solid var(--line); color: var(--muted); width: 34px; height: 34px; border-radius: 8px; cursor: pointer; display: grid; place-items: center; transition: .15s; }
.copy:hover { color: var(--accent); border-color: rgba(44,229,146,.3); }

.meta-row { display: flex; gap: 26px; flex-wrap: wrap; margin: 18px 0; }
.meta { }
.meta .k { font-size: 11.5px; color: var(--muted-2); text-transform: uppercase; letter-spacing: .6px; }
.meta .v { font-size: 15px; font-weight: 600; margin-top: 2px; }

.progress { height: 8px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.progress > i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent), var(--blue)); }

.acc-table { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 13.5px; }
.acc-table th { text-align: left; color: var(--muted-2); font-weight: 600; font-size: 11.5px; text-transform: uppercase; letter-spacing: .5px; padding: 8px 10px; border-bottom: 1px solid var(--line-soft); }
.acc-table td { padding: 11px 10px; border-bottom: 1px solid var(--line-soft); }
.acc-table tr:last-child td { border-bottom: 0; }
.empty { color: var(--muted-2); font-size: 13.5px; padding: 18px; text-align: center; border: 1px dashed var(--line); border-radius: 10px; }

/* konta + postacie (model licencja-per-konto) */
.accounts-wrap { display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
.account-block { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.account-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line-soft); }
.account-id { font-size: 14px; font-weight: 600; }
.account-id code { font-family: var(--mono); color: var(--accent); background: rgba(44,229,146,.08); padding: 2px 8px; border-radius: 6px; font-size: 13px; }
.account-meta { display: flex; gap: 10px; align-items: center; }
.badge.subtle { color: var(--muted-2); background: var(--panel-2); border-color: var(--line-soft); font-size: 11.5px; padding: 3px 9px; }
.char-list { display: flex; flex-direction: column; gap: 6px; }
.char-row { display: flex; align-items: center; gap: 12px; padding: 8px 4px; border-radius: 8px; transition: background .12s; }
.char-row:hover { background: rgba(255,255,255,.02); }
.char-avatar { width: 30px; height: 45px; border-radius: 4px; background: var(--panel-2); flex-shrink: 0; object-fit: none; object-position: top left; border: 1px solid var(--line-soft); image-rendering: pixelated; cursor: help; }
.char-info { flex: 1; min-width: 0; }
.char-nick { font-weight: 600; font-size: 13.5px; }
.char-meta { color: var(--muted-2); font-size: 12px; margin-top: 2px; }
.char-last { font-size: 11.5px; flex-shrink: 0; }
.char-empty { padding: 12px; color: var(--muted-2); font-size: 12.5px; font-style: italic; }

.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line-soft); }

/* payment box */
.pay-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 16px 0; }
@media (max-width: 560px) { .pay-grid { grid-template-columns: 1fr; } }
.pay-item { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 10px; padding: 13px 15px; }
.pay-item .k { font-size: 11.5px; color: var(--muted-2); text-transform: uppercase; letter-spacing: .5px; }
.pay-item .v { font-size: 15px; font-weight: 600; margin-top: 3px; word-break: break-all; }
.code-banner { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: rgba(44,229,146,.07); border: 1px dashed rgba(44,229,146,.4); border-radius: 12px; padding: 16px 18px; margin: 14px 0; flex-wrap: wrap; }
.code-banner .code { font-family: var(--mono); font-size: 22px; font-weight: 700; color: var(--accent); letter-spacing: 1px; }

/* toast */
.toast-host { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; }
.toast { background: var(--panel-2); border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 10px; padding: 12px 16px; font-size: 14px; box-shadow: var(--shadow); animation: pop .2s ease; }
.toast.err { border-left-color: var(--danger); }
@keyframes pop { from { opacity: 0; transform: translateY(8px); } }

.hide { display: none !important; }
.stack > * + * { margin-top: 18px; }

/* modal */
.modal { position: fixed; inset: 0; z-index: 300; background: rgba(4,6,10,.7); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 22px; }
.modal-box { width: 100%; max-width: 520px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); animation: pop .18s ease; }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.steps { margin: 8px 0 4px; padding-left: 20px; }
.steps li { padding: 7px 0; color: var(--text); }
.steps code, p code { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; font-family: var(--mono); font-size: 12.5px; }

/* landing: lista cech dodatku */
.mini-list { list-style: none; padding: 0; margin: 14px 0 0; }
.mini-list li { position: relative; padding: 5px 0 5px 22px; color: var(--muted); font-size: 13.5px; }
.mini-list li::before { content: "›"; position: absolute; left: 4px; color: var(--accent); font-weight: 700; }

/* landing: numerki kroków */
.step-num { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(44,229,146,.12); border: 1px solid rgba(44,229,146,.3); color: var(--accent);
  font-weight: 800; margin-bottom: 12px; }

/* landing: wiersz cennika */
.price-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.price-name { font-weight: 700; font-size: 16px; }
.price-amount { font-weight: 800; font-size: 20px; color: var(--accent); white-space: nowrap; }
