/* =========================================================
   Winietki – Jaworski Music
   Kolory i typografia przeniesione 1:1 ze strony jaworskimusic.pl
   ========================================================= */
:root {
  color-scheme: light;
  --green: #004d40;
  --green-dark: #00382f;
  --green-tint: rgba(0, 77, 64, 0.08);
  --cream: #f7f4eb;
  --umber: #352100;
  --ink: #1a2e2b;
  --muted: #4a5d5a;
  --muted-2: #6b7c79;
  --line: #e7e1d1;
  --card: #ffffff;
  --card-soft: #f7fdfd;
  --amber: #7a4f00;
  --amber-bg: #fcf1d8;
  --ok: #0d6046;
  --ok-bg: #e1f1e9;
  --danger: #a3122e;
  --danger-bg: #fbe7ea;
  --bg: #ffffff;
  --input-bg: #ffffff;
  --line-strong: #dcd5c3;
  --line-soft: #f1ede3;
  --line-warm: var(--line-warm);
  --fill: #004d40;
  --fill-hover: #352100;
  --on-fill: #ffffff;
  --umber-ink: #352100;
  --footer-bg: #004d40;
  --warn-ink: #5a3a00;
  --ok-ink: #0b4a37;
  --err-ink: #7a0d22;
  --danger-line: #f0c9d0;
  --danger-fill: #a3122e;
  --amber-bg-2: #fdf3e0;
  --amber-line: #f0d9a8;
  --neutral-bg: #eeede8;
  --neutral-ink: #6d6c66;
  --glass: rgba(255, 255, 255, 0.85);
  --glass-strong: rgba(255, 255, 255, 0.97);
  --glass-card: rgba(255, 255, 255, 0.86);
  --glass-chip: rgba(255, 255, 255, 0.92);
  --cloth-a: #fbfaf6;
  --cloth-b: #f1ede2;
  --cloth-fade: rgba(241, 237, 226, 0);
  --focus: rgba(0, 77, 64, 0.35);
  --focus-soft: rgba(0, 77, 64, 0.12);
  --switch-off: #d9d3c4;
  --pip-off: rgba(26, 46, 43, 0.14);
  --empty-bg: #eef1f0;
  --empty-line: #b9c2c0;
  --spent-bg: #d9dedd;
  --spent-ink: #7b8987;
  --toast-bg: #1a2e2b;
  --mark-bg: #fff1a8;
  --modal-backdrop: rgba(26, 46, 43, 0.45);
  --bg-photo-opacity: 0.32;
  --g-bg: #ffffff;
  --g-ink: #1f1f1f;
  --g-line: #dadce0;
  --g-hover-bg: #f8faff;
  --g-hover-line: #c6d2f5;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-card: 0 15px 30px rgba(0, 77, 64, 0.08);
  --shadow-paper: 0 1px 2px rgba(26, 46, 43, 0.08), 0 14px 34px rgba(26, 46, 43, 0.16);
  --font: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
img, svg { max-width: 100%; }
a { color: var(--green); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* tło jak na stronie głównej: rozmyte zdjęcie z realizacji */
.bg-photo {
  position: fixed; inset: 0; z-index: -1;
  background: var(--bg-image, none) center / cover no-repeat;
  filter: blur(14px); opacity: var(--bg-photo-opacity); transform: scale(1.15);
  pointer-events: none;
}

h1, h2, h3, h4 { color: var(--green); line-height: 1.2; margin: 0; font-weight: 700; }
h1 { font-size: clamp(2rem, 4.6vw, 3rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
h3 { font-size: 1.25rem; }
p { margin: 0; }
.lead { font-size: 1.08rem; color: var(--muted); max-width: 34em; }
.muted { color: var(--muted); }
.small { font-size: 0.875rem; }
.tiny { font-size: 0.78rem; }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 20px; }

/* ---------- nawigacja ---------- */
.topbar {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: var(--glass);
  backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
  border-bottom: 1px solid rgba(74, 93, 90, 0.1);
}
.topbar .container { display: flex; align-items: center; gap: 16px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand img { height: 40px; width: auto; display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-text b { white-space: nowrap; font-family: "Times New Roman", serif; font-size: 1.35rem; letter-spacing: 0.02em; color: var(--ink); }
.brand-text small { font-size: 0.62rem; color: var(--muted); margin-top: 4px; }
.brand-app { padding-left: 12px; margin-left: 2px; border-left: 1px solid var(--line); font-weight: 700; color: var(--green); font-size: 0.95rem; }
.nav { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.nav a, .nav button.link {
  text-decoration: none; color: var(--ink); font-weight: 600; font-size: 0.9rem;
  padding: 8px 12px; border-radius: 999px; border: 0; background: none; cursor: pointer; white-space: nowrap;
}
/* średnie ekrany: menu z „Dane kontaktowe” i panelem admina musi się zmieścić w jednej linii */
@media (max-width: 1180px) and (min-width: 921px) {
  .brand-app { display: none; }
  .nav { gap: 2px; }
  .nav a, .nav button.link { padding: 8px 9px; font-size: 0.86rem; }
}
.nav a:hover, .nav button.link:hover { color: var(--green); background: var(--green-tint); }
.nav a[aria-current="page"] { color: var(--green); background: var(--green-tint); }
.nav .admin-link { color: var(--umber-ink); }
.account { position: relative; }
.avatar {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: var(--cream);
  color: var(--green); font-weight: 700; cursor: pointer; display: grid; place-items: center;
}
.account-menu {
  position: absolute; right: 0; top: 48px; min-width: 240px; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius-md); box-shadow: var(--shadow-card); padding: 8px; z-index: 60;
}
.account-menu .who { padding: 10px 12px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; font-size: 0.85rem; word-break: break-all; }
.account-menu a, .account-menu button {
  display: block; width: 100%; text-align: left; padding: 10px 12px; border-radius: 10px; border: 0; background: none;
  text-decoration: none; color: var(--ink); font-weight: 600; font-size: 0.9rem; cursor: pointer;
}
.account-menu a:hover, .account-menu button:hover { background: var(--green-tint); color: var(--green); }
.nav-toggle { display: none; margin-left: auto; border: 1px solid var(--line); background: var(--card); border-radius: 12px; width: 44px; height: 44px; cursor: pointer; }
.nav-toggle span { display: block; width: 18px; height: 2px; background: var(--ink); margin: 4px auto; border-radius: 2px; }

@media (max-width: 920px) {
  .nav-toggle { display: block; }
  .brand-app { display: none; }
  .nav {
    position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; align-items: stretch;
    background: var(--glass-strong); border-bottom: 1px solid var(--line); padding: 10px 16px 16px; gap: 2px;
    display: none;
  }
  .nav.open { display: flex; }
  .nav a, .nav button.link { padding: 12px 14px; }
  .account-menu { position: static; box-shadow: none; margin-top: 6px; }
  .avatar { display: none; }
}

.demo-banner {
  background: var(--umber); color: #fdf6e6; font-size: 0.85rem; text-align: center; padding: 8px 16px;
}
.demo-banner button { background: none; border: 0; color: #fff; text-decoration: underline; cursor: pointer; font-weight: 600; padding: 0 4px; }

main { flex: 1; outline: none; }

/* ---------- przyciski ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 28px; border-radius: 999px; border: 1px solid transparent;
  font-weight: 700; font-size: 0.95rem; text-decoration: none; cursor: pointer; line-height: 1.2;
  transition: transform 0.4s var(--ease), background 0.3s, box-shadow 0.4s var(--ease), color 0.3s, border-color 0.3s;
  white-space: nowrap;
}
.btn-primary { background: var(--fill); color: var(--on-fill); box-shadow: 0 4px 15px rgba(0, 77, 64, 0.18); }
.btn-primary:hover:not(:disabled) { background: var(--fill-hover); transform: translateY(-2px); box-shadow: 0 10px 20px rgba(53, 33, 0, 0.2); }
.btn-ghost { background: var(--card); color: var(--green); border-color: var(--line); }
.btn-ghost:hover:not(:disabled) { border-color: var(--green); }
.btn-quiet { background: transparent; color: var(--green); padding: 10px 14px; }
.btn-quiet:hover:not(:disabled) { background: var(--green-tint); }
.btn-danger { background: var(--card); color: var(--danger); border-color: var(--danger-line); }
.btn-danger:hover:not(:disabled) { background: var(--danger-bg); }
.btn-sm { padding: 9px 16px; font-size: 0.85rem; }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn .spin { width: 16px; height: 16px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.google-btn { background: var(--g-bg); color: var(--g-ink); border: 1px solid var(--g-line); font-weight: 600; }
.google-btn:hover:not(:disabled) { background: var(--g-hover-bg); border-color: var(--g-hover-line); }
.google-btn svg { width: 18px; height: 18px; }

/* ---------- formularze ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span, .field > label, .label { font-weight: 600; font-size: 0.88rem; color: var(--ink); }
.field .hint { font-size: 0.8rem; color: var(--muted-2); }
.input, select.input, textarea.input {
  width: 100%; border: 1px solid var(--line-strong); background: var(--input-bg); border-radius: 12px; padding: 12px 14px; font-size: 0.95rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
textarea.input { resize: vertical; min-height: 110px; line-height: 1.5; }
.input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px var(--focus-soft); }
.input[aria-invalid="true"] { border-color: var(--danger); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 0.88rem; color: var(--muted); cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--green); flex: none; }
.error-text { color: var(--danger); font-size: 0.85rem; font-weight: 600; }

.choice-row { display: flex; flex-wrap: wrap; gap: 8px; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice span {
  display: inline-block; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--card);
  font-weight: 600; font-size: 0.88rem; transition: all 0.2s;
}
.choice input:checked + span { background: var(--fill); border-color: var(--fill); color: var(--on-fill); }
.choice input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }

/* ---------- ogólne bloki ---------- */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; }
.panel-soft { background: var(--card-soft); }
.section { padding: 72px 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 28px; flex-wrap: wrap; }
.section-head p { max-width: 36em; }
.page { padding: 40px 0 72px; }
.page-head { margin-bottom: 28px; display: flex; gap: 16px; align-items: end; justify-content: space-between; flex-wrap: wrap; }
.page-head p { margin-top: 8px; }
.page-head h1 { font-size: clamp(1.8rem, 3.6vw, 2.4rem); }
.back { display: inline-flex; gap: 6px; align-items: center; color: var(--green); font-weight: 700; text-decoration: none; font-size: 0.85rem; margin-bottom: 14px; }
.back:hover { color: var(--umber-ink); }

.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 700; white-space: nowrap; }
.chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.chip-pending { background: var(--amber-bg); color: var(--amber); }
.chip-paid { background: var(--ok-bg); color: var(--ok); }
.chip-cancelled { background: var(--neutral-bg); color: var(--neutral-ink); }
.tag { display: inline-block; background: var(--green-tint); color: var(--green); font-size: 0.75rem; font-weight: 700; padding: 4px 12px; border-radius: 999px; }

.notice { border-radius: var(--radius-md); padding: 14px 16px; font-size: 0.9rem; display: flex; gap: 12px; align-items: flex-start; }
.notice-info { background: var(--cream); color: var(--ink); }
.notice-warn { background: var(--amber-bg); color: var(--warn-ink); }
.notice-ok { background: var(--ok-bg); color: var(--ok-ink); }
.notice-error { background: var(--danger-bg); color: var(--err-ink); }
.notice b { font-weight: 700; }

.empty { text-align: center; padding: 56px 24px; }
.empty h3 { margin-bottom: 8px; }
.empty p { color: var(--muted); margin-bottom: 20px; }

.loading { display: grid; place-items: center; min-height: 40vh; color: var(--muted); }
.loading .spin { width: 28px; height: 28px; border: 3px solid var(--green); border-right-color: transparent; border-radius: 50%; animation: spin 0.8s linear infinite; margin: 0 auto 12px; }

/* ---------- strona startowa ---------- */
.hero { padding: 56px 0 40px; }
.hero .container { display: grid; grid-template-columns: 1.02fr 1fr; gap: 40px; align-items: center; }
.hero h1 { max-width: 13em; }
.hero .lead { margin-top: 18px; }
.hero-actions { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.hero-facts { display: flex; gap: 22px; margin-top: 26px; flex-wrap: wrap; font-size: 0.85rem; color: var(--muted); }
.hero-facts span { display: inline-flex; gap: 8px; align-items: center; }
.hero-facts svg { width: 18px; height: 18px; color: var(--green); flex: none; }
.hero-table {
  position: relative; aspect-ratio: 1.12; min-height: 320px;
}
.hero-table .paper {
  position: absolute; width: 74%; border-radius: 3px; box-shadow: var(--shadow-paper); background: #fff; line-height: 0;
  transform-origin: 50% 80%;
}
.hero-table .paper svg { width: 100%; height: auto; display: block; border-radius: 3px; }
.hero-table .p1 { left: 0; top: 4%; transform: rotate(-7deg); }
.hero-table .p2 { right: 0; top: 30%; transform: rotate(5deg); }
.hero-table .p3 { left: 10%; top: 56%; transform: rotate(-2deg); }
@media (prefers-reduced-motion: no-preference) {
  .hero-table .paper { animation: deal 0.9s var(--ease) both; }
  .hero-table .p2 { animation-delay: 0.12s; }
  .hero-table .p3 { animation-delay: 0.24s; }
  @keyframes deal { from { opacity: 0; translate: 0 26px; rotate: 6deg; } }
}
@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero-table { max-width: 520px; width: 100%; margin: 10px auto 0; min-height: 0; }
}

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; counter-reset: step; }
.step { position: relative; padding: 22px 20px; border-radius: var(--radius-lg); background: var(--glass-card); border: 1px solid var(--line); }
.step b { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--fill); color: var(--on-fill); font-size: 0.9rem; margin-bottom: 14px; }
.step h3 { font-size: 1.02rem; margin-bottom: 6px; color: var(--ink); }
.step p { font-size: 0.88rem; color: var(--muted); }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

.seg { display: inline-flex; background: var(--cream); padding: 4px; border-radius: 999px; gap: 2px; flex-wrap: wrap; }
.seg button {
  border: 0; background: none; padding: 9px 16px; border-radius: 999px; font-weight: 600; font-size: 0.86rem; cursor: pointer; color: var(--muted);
}
.seg button[aria-pressed="true"] { background: var(--card); color: var(--green); box-shadow: 0 1px 4px rgba(26, 46, 43, 0.12); }

.tpl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.tpl-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px; }
.tpl-card .sheet { line-height: 0; box-shadow: 0 1px 2px rgba(26, 46, 43, 0.1), 0 6px 16px rgba(26, 46, 43, 0.08); border-radius: 2px; overflow: hidden; }
.tpl-card .sheet svg { width: 100%; height: auto; display: block; }
.tpl-card h3 { font-size: 1rem; margin-top: 14px; color: var(--ink); }
.tpl-card p { font-size: 0.84rem; color: var(--muted); }
@media (max-width: 900px) { .tpl-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .tpl-grid { grid-template-columns: 1fr; } }

.pricing { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.price-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px 18px 20px;
  display: flex; flex-direction: column; gap: 4px; text-align: center;
  transition: border-color 0.3s, transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.price-card:hover { border-color: var(--green); transform: translateY(-4px); box-shadow: var(--shadow-card); }
.price-card .qty { font-size: 2.2rem; font-weight: 800; color: var(--green); line-height: 1; }
.price-card .unit { font-size: 0.8rem; color: var(--muted); margin-bottom: 14px; }
.price-card .price { font-size: 1.6rem; font-weight: 700; color: var(--ink); }
.price-card .per { font-size: 0.78rem; color: var(--muted-2); margin-bottom: 18px; }
.price-card .btn { margin-top: auto; }
@media (max-width: 1000px) { .pricing { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 620px) { .pricing { grid-template-columns: 1fr 1fr; } }
.pricing-note { margin-top: 18px; font-size: 0.85rem; color: var(--muted); }

.faq { display: grid; gap: 12px; max-width: 820px; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 15px; overflow: hidden; }
.faq summary { padding: 20px 24px; cursor: pointer; font-weight: 700; color: var(--green); list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.3rem; line-height: 1; transition: transform 0.3s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 24px 20px; color: var(--muted); font-size: 0.93rem; }

.site-footer { background: var(--footer-bg); color: #f7f4eb; padding: 40px 0; font-size: 0.88rem; }

/* ---------- reklama: Wedding Planner ---------- */
.promo {
  display: grid; grid-template-columns: auto 1fr auto; gap: 18px; align-items: center;
  background: var(--cream); border: 1px solid var(--line-warm); border-radius: var(--radius-lg); padding: 22px 24px;
}
.promo-icon { width: 52px; height: 52px; border-radius: 14px; background: var(--fill); color: var(--on-fill); display: grid; place-items: center; flex: none; }
.promo-icon svg { width: 26px; height: 26px; }
.promo-text { display: grid; gap: 4px; min-width: 0; }
.promo-text b { color: var(--green); font-size: 1.08rem; line-height: 1.3; }
.promo-text span { color: var(--muted); font-size: 0.92rem; }
.promo-compact { padding: 16px 18px; gap: 14px; }
.promo-compact .promo-icon { width: 40px; height: 40px; border-radius: 11px; }
.promo-compact .promo-icon svg { width: 21px; height: 21px; }
.promo-compact .promo-text b { font-size: 0.95rem; }
.promo-compact .promo-text span { font-size: 0.84rem; }
.editor-body .promo { grid-template-columns: auto 1fr; }
.editor-body .promo .btn { grid-column: 1 / -1; }
@media (max-width: 640px) {
  .promo { grid-template-columns: auto 1fr; }
  .promo .btn { grid-column: 1 / -1; }
}
.promo-strip { background: var(--cream); border-top: 1px solid var(--line-warm); margin-top: 40px; }
.promo-strip-inner { display: flex; align-items: center; gap: 14px; padding-top: 16px; padding-bottom: 16px; flex-wrap: wrap; }
.promo-strip .promo-icon { width: 36px; height: 36px; border-radius: 10px; }
.promo-strip .promo-icon svg { width: 19px; height: 19px; }
.promo-strip p { flex: 1; min-width: 220px; font-size: 0.9rem; color: var(--ink); }
.promo-strip p b { color: var(--green); }
.promo-strip a { font-weight: 700; color: var(--on-fill); background: var(--fill); padding: 9px 18px; border-radius: 999px; text-decoration: none; font-size: 0.85rem; white-space: nowrap; transition: background 0.3s; }
.promo-strip a:hover { background: var(--fill-hover); }
.site-footer .container { display: flex; gap: 20px; justify-content: space-between; flex-wrap: wrap; align-items: center; }
.site-footer a { color: #fff; }

/* ---------- zamówienie ---------- */
.order-layout { display: grid; grid-template-columns: 1fr 340px; gap: 28px; align-items: start; }
.order-summary { position: sticky; top: 96px; }
.order-summary dl { margin: 16px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; font-size: 0.9rem; }
.order-summary dt { color: var(--muted); }
.order-summary dd { margin: 0; font-weight: 600; text-align: right; }
.order-summary .total { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 16px; display: flex; justify-content: space-between; align-items: baseline; }
.order-summary .total b { font-size: 1.6rem; color: var(--green); }
@media (max-width: 900px) { .order-layout { grid-template-columns: 1fr; } .order-summary { position: static; } }

.pkg-options { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.pkg-option { position: relative; }
.pkg-option input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.pkg-option span { display: flex; flex-direction: column; align-items: center; padding: 14px 8px; border: 1px solid var(--line-strong); border-radius: var(--radius-md); background: var(--card); transition: all 0.2s; }
.pkg-option b { font-size: 1.3rem; color: var(--green); }
.pkg-option small { color: var(--muted); font-size: 0.8rem; }
.pkg-option input:checked + span { border-color: var(--fill); background: var(--fill); }
.pkg-option input:checked + span b, .pkg-option input:checked + span small { color: #fff; }
.pkg-option input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
@media (max-width: 560px) { .pkg-options { grid-template-columns: repeat(2, 1fr); } }
.pkg-option { min-width: 0; }

.code-badge { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-weight: 700; letter-spacing: 0.06em; color: var(--green); }
.success-hero { text-align: center; max-width: 640px; margin: 0 auto; }
.success-hero .code-big { font-size: clamp(1.8rem, 6vw, 2.6rem); margin: 14px 0 6px; display: block; }
.success-hero .tick { width: 64px; height: 64px; border-radius: 50%; background: var(--ok-bg); color: var(--ok); display: grid; place-items: center; margin: 0 auto 18px; }

/* ---------- moje zamówienia ---------- */
.order-list { display: grid; gap: 16px; }
.order-card { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: start; }
.order-card .meta { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 8px; font-size: 0.9rem; color: var(--muted); }
.order-card .meta b { color: var(--ink); font-weight: 600; }
.order-card .side { text-align: right; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.order-card .amount { font-size: 1.3rem; font-weight: 700; }
.order-card .next { grid-column: 1 / -1; }
.bank { display: grid; grid-template-columns: auto 1fr auto; gap: 8px 14px; align-items: center; font-size: 0.92rem; margin-top: 10px; }
.bank dt { color: var(--muted); }
.bank dd { margin: 0; font-weight: 600; word-break: break-word; }
.copy-btn { border: 1px solid var(--line); background: var(--card); border-radius: 8px; padding: 4px 10px; font-size: 0.78rem; font-weight: 600; cursor: pointer; color: var(--green); }
.copy-btn:hover { border-color: var(--green); }
@media (max-width: 640px) {
  .order-card { grid-template-columns: 1fr; }
  .order-card .side { text-align: left; align-items: flex-start; }
}

/* ---------- panel admina ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-bottom: 22px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 16px 18px; }
.stat b { display: block; font-size: 1.6rem; color: var(--green); line-height: 1.1; }
.stat span { font-size: 0.82rem; color: var(--muted); }

.toolbar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.toolbar .input { max-width: 300px; padding: 10px 14px; }
.admin-tabs { margin-bottom: 24px; }
.adm-list { display: grid; gap: 12px; }
.adm-row { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 16px 18px; display: grid; grid-template-columns: 200px 1fr 220px 300px; gap: 16px; align-items: center; }
.adm-row.is-pending { border-left: 4px solid #e2b04a; }
.adm-row .who { font-size: 0.85rem; color: var(--muted); word-break: break-all; }
.adm-row .ev { font-size: 0.9rem; }
.adm-row .ev b { font-weight: 600; }
.adm-row .money { text-align: right; }
.adm-row .money b { font-size: 1.1rem; display: block; }
.adm-row .actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.adm-row .note { grid-column: 1 / -1; font-size: 0.84rem; color: var(--muted); border-top: 1px dashed var(--line); padding-top: 10px; }
@media (max-width: 1100px) {
  .adm-row { grid-template-columns: 1fr auto; }
  .adm-row .ev { grid-column: 1 / -1; }
  .adm-row .actions { grid-column: 1 / -1; justify-content: flex-start; }
}
.menu-wrap { position: relative; }
.menu-pop { position: absolute; right: 0; top: 44px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-card); padding: 6px; z-index: 20; min-width: 200px; }
.menu-pop button { color: var(--ink); display: block; width: 100%; text-align: left; border: 0; background: none; padding: 10px 12px; border-radius: 8px; cursor: pointer; font-weight: 600; font-size: 0.88rem; }
.menu-pop button:hover { background: var(--green-tint); }
.menu-pop button.danger { color: var(--danger); }
.price-table { display: grid; gap: 10px; max-width: 520px; }
.price-row { display: grid; grid-template-columns: 120px 1fr 120px; gap: 14px; align-items: center; }
.price-row .input { padding: 10px 12px; }
.tpl-admin { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.tpl-admin label { display: block; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 12px; cursor: pointer; }
.tpl-admin label.off { opacity: 0.5; }
.tpl-admin svg { width: 100%; height: auto; display: block; border-radius: 2px; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1); }
.tpl-admin .row { display: flex; gap: 8px; align-items: center; margin-top: 10px; font-weight: 600; font-size: 0.9rem; }
.tpl-admin input { accent-color: var(--green); width: 18px; height: 18px; }
@media (max-width: 760px) { .tpl-admin { grid-template-columns: 1fr 1fr; } }

/* ---------- kreator ---------- */
.editor-top { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.editor-top h1 { font-size: 1.6rem; }
.editor-top .meta { color: var(--muted); font-size: 0.88rem; }
.editor-top .spacer { flex: 1; }
.counter { font-weight: 700; font-size: 0.9rem; padding: 8px 14px; border-radius: 999px; background: var(--cream); }
.counter.over { background: var(--danger-bg); color: var(--danger); }
.save-state { font-size: 0.8rem; color: var(--muted); }
.save-state.dirty { color: var(--amber); font-weight: 600; }
.save-state.auto { color: var(--ok); }

.editor { display: grid; grid-template-columns: 400px 1fr; gap: 24px; align-items: start; }
.editor-panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.editor-tabs { display: grid; grid-template-columns: repeat(5, 1fr); border-bottom: 1px solid var(--line); background: var(--card-soft); }
.editor-tabs button {
  border: 0; background: none; padding: 14px 4px 12px; cursor: pointer; font-weight: 600; font-size: 0.82rem; color: var(--muted);
  border-bottom: 3px solid transparent; display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.editor-tabs button b { font-size: 0.72rem; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--cream); color: var(--muted); }
.editor-tabs button[aria-selected="true"] { color: var(--green); border-bottom-color: var(--green); background: var(--card); }
.editor-tabs button[aria-selected="true"] b { background: var(--fill); color: var(--on-fill); }
.editor-body { padding: 22px; display: grid; gap: 22px; max-height: calc(100vh - 210px); overflow: auto; }
.editor-body h4 { font-size: 0.88rem; color: var(--ink); margin-bottom: 10px; }
.editor-body .seg button { padding: 8px 11px; font-size: 0.8rem; }
.mini-tpls { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mini-tpl { border: 2px solid transparent; border-radius: 10px; padding: 4px; background: none; cursor: pointer; text-align: left; }
.mini-tpl svg { width: 100%; height: auto; display: block; border-radius: 2px; box-shadow: 0 1px 4px rgba(26, 46, 43, 0.15); }
.mini-tpl small { display: block; font-size: 0.74rem; font-weight: 600; margin-top: 5px; color: var(--muted); }
.mini-tpl[aria-pressed="true"] { border-color: var(--green); }
.mini-tpl[aria-pressed="true"] small { color: var(--green); }
.fmt-list { display: grid; gap: 8px; }
.fmt { display: flex; gap: 12px; align-items: center; border: 1px solid var(--line-strong); border-radius: 12px; padding: 10px 12px; cursor: pointer; }
.fmt input { accent-color: var(--green); }
.fmt b { display: block; font-size: 0.9rem; }
.fmt small { color: var(--muted); font-size: 0.78rem; }
.fmt:has(input:checked) { border-color: var(--green); background: var(--card-soft); }
.font-list { display: grid; gap: 6px; max-height: 300px; overflow: auto; padding-right: 4px; }
.font-opt { display: flex; align-items: center; justify-content: space-between; gap: 10px; border: 1px solid var(--line); border-radius: 10px; padding: 6px 12px; cursor: pointer; background: var(--card); text-align: left; }
.font-opt .sample { font-size: 1.45rem; line-height: 1.3; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.font-opt small { color: var(--muted-2); font-size: 0.7rem; white-space: nowrap; }
.font-opt[aria-pressed="true"] { border-color: var(--green); background: var(--card-soft); }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.swatch { width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--card); box-shadow: 0 0 0 1px var(--line-strong); cursor: pointer; }
.swatch[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--green); }
.swatches input[type="color"] { width: 36px; height: 36px; border: 0; padding: 0; background: none; cursor: pointer; }
.range-row { display: flex; gap: 12px; align-items: center; }
.range-row input { flex: 1; accent-color: var(--green); }
.guest-table { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.guest-table .head, .guest-row { display: grid; grid-template-columns: 30px 1fr 64px 34px; gap: 6px; align-items: center; padding: 6px 8px; }
.guest-table .head { background: var(--cream); font-size: 0.75rem; font-weight: 700; color: var(--muted); }
.guest-rows { max-height: 340px; overflow: auto; }
.guest-row { border-top: 1px solid var(--line-soft); }
.guest-row .n { font-size: 0.72rem; color: var(--muted-2); text-align: right; }
.guest-row input { border: 1px solid transparent; border-radius: 8px; padding: 6px 8px; width: 100%; font-size: 0.88rem; background: transparent; }
.guest-row input:hover { border-color: var(--line); }
.guest-row input:focus { outline: none; border-color: var(--green); background: var(--input-bg); }
.guest-row button { border: 0; background: none; cursor: pointer; color: var(--muted-2); border-radius: 8px; height: 30px; }
.guest-row button:hover { background: var(--danger-bg); color: var(--danger); }
.guest-row.selected { background: var(--card-soft); }
.guest-row.warn input:first-of-type { color: var(--danger); }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.file-drop { border: 1.5px dashed var(--line-strong); border-radius: 14px; padding: 18px; text-align: center; font-size: 0.88rem; color: var(--muted); background: var(--card-soft); transition: border-color 0.2s, background 0.2s; }
.file-drop.over { border-color: var(--green); background: var(--green-tint); }
.file-drop label { color: var(--green); font-weight: 700; cursor: pointer; text-decoration: underline; }

.stage { display: grid; gap: 18px; }
.stage-main { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; }
.table-cloth {
  background: radial-gradient(ellipse at 50% 40%, var(--cloth-a) 0%, var(--cloth-b) 100%);
  border-radius: var(--radius-md); padding: clamp(18px, 5vw, 48px); display: grid; place-items: center; min-height: 300px;
}
.table-cloth .paper { width: min(100%, 560px); box-shadow: var(--shadow-paper); line-height: 0; border-radius: 2px; overflow: hidden; background: #fff; }
.table-cloth .paper.sheet { width: min(100%, 360px); }
.table-cloth .paper svg { width: 100%; height: auto; display: block; }
.stage-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.stage-nav .who { font-weight: 600; text-align: center; flex: 1; min-width: 160px; }
.stage-nav .who small { display: block; color: var(--muted); font-weight: 500; }
.icon-btn { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); cursor: pointer; display: grid; place-items: center; color: var(--green); }
.icon-btn:hover:not(:disabled) { border-color: var(--green); }
.icon-btn:disabled { opacity: 0.4; cursor: default; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.thumb { border: 2px solid transparent; padding: 3px; border-radius: 8px; background: none; cursor: pointer; line-height: 0; position: relative; }
.thumb svg { width: 100%; height: auto; display: block; box-shadow: 0 1px 4px rgba(26, 46, 43, 0.14); border-radius: 2px; }
.thumb[aria-pressed="true"] { border-color: var(--green); }
.thumb .flag { position: absolute; top: 8px; right: 8px; background: var(--danger-fill); color: #fff; font-size: 0.65rem; line-height: 1; padding: 4px 6px; border-radius: 999px; font-weight: 700; }
.pager { display: flex; gap: 10px; align-items: center; justify-content: center; margin-top: 14px; font-size: 0.85rem; }
.progress { height: 8px; background: var(--cream); border-radius: 999px; overflow: hidden; }
.progress i { display: block; height: 100%; width: 0; background: var(--fill); transition: width 0.25s; }
.export-card { border: 1px solid var(--line); border-radius: 14px; padding: 16px; display: grid; gap: 10px; }
.export-card h4 { margin: 0 !important; }
.export-card p { font-size: 0.84rem; color: var(--muted); }
@media (max-width: 1020px) {
  .editor { grid-template-columns: 1fr; }
  .stage { display: contents; }
  .stage-main { order: 1; }
  .editor-panel { order: 2; }
  #thumbs-panel { order: 3; }
  .editor-body { max-height: none; }
}
@media (max-width: 560px) {
  .panel, .stage-main { padding: 18px; }
  .thumbs { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .editor-body { padding: 18px; }
  .editor-top h1 { font-size: 1.35rem; }
}

/* ---------- okno dialogowe i komunikaty ---------- */
dialog.modal {
  border: 0; border-radius: var(--radius-lg); padding: 0; width: min(520px, calc(100vw - 28px)); max-height: calc(100vh - 40px);
  box-shadow: 0 30px 80px rgba(26, 46, 43, 0.3); color: var(--ink); background: var(--card);
}
dialog.modal::backdrop { background: var(--modal-backdrop); backdrop-filter: blur(3px); }
.modal-inner { padding: 28px; display: grid; gap: 18px; }
.modal-head { display: flex; justify-content: space-between; align-items: start; gap: 16px; }
.modal-head h2 { font-size: 1.35rem; }
.modal-close { border: 0; background: var(--cream); width: 36px; height: 36px; border-radius: 50%; cursor: pointer; font-size: 1.2rem; line-height: 1; flex: none; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--muted-2); font-size: 0.8rem; }
.divider::before, .divider::after { content: ""; height: 1px; background: var(--line); flex: 1; }
.auth-switch { text-align: center; font-size: 0.88rem; color: var(--muted); }
.auth-switch button { border: 0; background: none; color: var(--green); font-weight: 700; cursor: pointer; padding: 0; text-decoration: underline; }
.toast-root { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 100; display: grid; gap: 8px; width: min(440px, calc(100vw - 24px)); }
.toast { background: var(--toast-bg); color: #fff; padding: 12px 16px; border-radius: 12px; font-size: 0.9rem; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2); }
.toast.ok { background: var(--fill); }
.toast.error { background: var(--danger-fill); }
@media (prefers-reduced-motion: no-preference) {
  .toast { animation: toast-in 0.35s var(--ease); }
  @keyframes toast-in { from { opacity: 0; translate: 0 10px; } }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ---------- darmowe winietki i zwiększanie pakietu ---------- */
.free-tag { display: inline-block; background: var(--green-tint); color: var(--green); font-size: 0.72rem; font-weight: 700; padding: 2px 9px; border-radius: 999px; white-space: nowrap; vertical-align: middle; }
.price-card .free-tag { margin: -8px auto 12px; font-size: 0.78rem; padding: 4px 12px; }
.pkg-option .free-tag { margin-top: 4px; font-size: 0.66rem; padding: 1px 7px; }
.pkg-option input:checked + span .free-tag { background: rgba(255, 255, 255, 0.18); color: #fff; }
.upgrade-req { grid-column: 1 / -1; display: flex; gap: 14px; justify-content: space-between; align-items: center; flex-wrap: wrap; background: var(--amber-bg); border-radius: 12px; padding: 12px 14px; font-size: 0.9rem; color: var(--warn-ink); }
.upgrade-req .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.counter small { font-weight: 600; color: var(--green); margin-left: 4px; }
.blank-box { display: grid; grid-template-columns: 1fr 120px; gap: 14px; align-items: center; }
.blank-box svg { width: 100%; height: auto; display: block; box-shadow: 0 1px 4px rgba(26, 46, 43, 0.15); border-radius: 2px; }
.num-row { display: flex; align-items: center; gap: 10px; }
.num-row input { width: 80px; }
.thumb .count { position: absolute; bottom: 8px; right: 8px; background: var(--fill); color: var(--on-fill); font-size: 0.68rem; line-height: 1; padding: 4px 7px; border-radius: 999px; font-weight: 700; }

.tpl-card .sheet { position: relative; }
.badge-new { position: absolute; top: 8px; left: 8px; background: var(--fill); color: var(--on-fill); font-size: 0.7rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; line-height: 1.2; }
.mini-tpl small .free-tag { font-size: 0.6rem; padding: 1px 6px; }


/* =========================================================
   Książeczki na stół, kody rabatowe, zgody, wygaszenie, konto
   ========================================================= */
.sunset-banner { background: #3a1d0e; color: #fff4e3; font-size: 0.88rem; }
.sunset-banner .container { display: flex; gap: 12px; align-items: center; padding-top: 10px; padding-bottom: 10px; }
.sunset-banner svg { flex: none; color: #ffcf8a; }
.sunset-banner p { margin: 0; }
.sunset-banner .countdown { color: #ffcf8a; white-space: nowrap; font-variant-numeric: tabular-nums; }
.linklike { border: 0; background: none; padding: 0; color: var(--green); font: inherit; font-weight: 700; text-decoration: underline; cursor: pointer; }
mark { background: var(--mark-bg); color: inherit; padding: 0 3px; border-radius: 3px; }

/* banderola „Produkty cyfrowe” */
.digital-ribbon { display: inline-flex; align-items: center; gap: 10px; background: var(--card); border: 1.5px solid var(--green); color: var(--green); border-radius: 999px; padding: 8px 18px 8px 12px; font-size: 0.92rem; margin-bottom: 18px; box-shadow: 0 6px 18px rgba(0, 77, 64, 0.08); }
.digital-ribbon svg { flex: none; }
.digital-ribbon b { font-weight: 800; }
.digital-ribbon.compact { font-size: 0.8rem; padding: 5px 14px 5px 9px; margin: 4px 0 14px; box-shadow: none; }
.digital-ribbon.compact svg { width: 18px; height: 18px; }
.disclaimer { font-size: 0.84rem; color: var(--warn-ink); background: var(--amber-bg); border-radius: 12px; padding: 12px 14px; }
.order-summary .digital-ribbon { display: flex; }

/* strona startowa */
.steps-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .steps-3 { grid-template-columns: 1fr; } }
.eyebrow { display: inline-block; font-size: 0.75rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; color: var(--umber-ink); margin-bottom: 8px; }
.booklet-promo { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 36px; align-items: center; }
.booklet-promo h2 { margin-bottom: 12px; }
.ticks { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; font-size: 0.92rem; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; }
.ticks svg { width: 18px; height: 18px; color: var(--green); flex: none; margin-top: 3px; }
.booklet-show { position: relative; display: grid; place-items: center; background: radial-gradient(ellipse at 50% 40%, var(--cloth-a) 0%, var(--cloth-b) 100%); border-radius: var(--radius-lg); padding: 12px 10px 18px; overflow: hidden; }
.booklet-show .paper { box-shadow: var(--shadow-paper); line-height: 0; border-radius: 2px; overflow: hidden; background: #fff; }
.booklet-show .paper:nth-child(1) { transform: rotate(-1.5deg); }
.booklet-show .paper:nth-child(2) { transform: rotate(1.5deg) translateY(16px); }
.booklet-show svg { width: 100%; height: auto; display: block; }
@media (max-width: 900px) { .booklet-promo { grid-template-columns: 1fr; } }


.promo-banner { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: baseline; background: var(--amber-bg-2); border: 1px solid var(--amber-line); color: var(--warn-ink); border-radius: var(--radius-md); padding: 14px 18px; margin-bottom: 16px; }
.promo-banner .small { flex-basis: 100%; }
.price-card { position: relative; }
.price-card .price { white-space: nowrap; }
.price-card .price-old { font-size: 0.82rem; color: var(--danger); font-weight: 700; }
.price-card .price-old s { color: var(--muted-2); font-weight: 500; }
.price-card .price-sm { font-size: 1.15rem; }
.price-card .qty-range { font-size: 1.6rem; }
.omnibus { font-size: 0.72rem; color: var(--muted-2); line-height: 1.35; }
.tag-start { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); background: var(--umber); color: #fff; font-size: 0.68rem; font-weight: 800; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.addon-card { margin-top: 16px; display: flex; gap: 20px; justify-content: space-between; align-items: center; flex-wrap: wrap; background: var(--cream); border: 1px solid var(--line-warm); border-radius: var(--radius-lg); padding: 20px 24px; }
.addon-card h3 { font-size: 1.1rem; margin-bottom: 4px; }
.addon-price { display: grid; text-align: right; }
.addon-price b { font-size: 1.6rem; color: var(--green); line-height: 1.1; }
.addon-price span { font-size: 0.82rem; color: var(--muted); }
.price-details { margin-top: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-md); }
.price-details summary { padding: 16px 20px; cursor: pointer; font-weight: 700; color: var(--green); }
.price-details .table-wrap { padding: 0 20px 18px; display: grid; gap: 18px; }
.table-wrap { overflow-x: auto; }
.price-table-full, .legal-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.price-table-full caption { text-align: left; font-weight: 700; color: var(--ink); padding: 6px 0 8px; }
.price-table-full th, .price-table-full td, .legal-table th, .legal-table td { border-bottom: 1px solid var(--line); padding: 9px 10px; text-align: left; vertical-align: top; }
.price-table-full th, .legal-table th { background: var(--cream); font-size: 0.8rem; color: var(--muted); }

/* zamówienie */
.addon-field { border: 1px solid var(--line); border-radius: var(--radius-md); padding: 16px 18px; display: grid; gap: 12px; }
.addon-field legend { padding: 0 6px; }
.bk-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.bk-grid .suggest { grid-column: 1 / -1; font-size: 0.88rem; background: var(--card-soft); border-radius: 10px; padding: 10px 12px; }
@media (max-width: 560px) { .bk-grid { grid-template-columns: 1fr; } }
.promo-row { display: flex; gap: 8px; }
.promo-row .input { max-width: 320px; }
.ok-text { color: var(--ok); font-weight: 600; }
.consents { display: grid; gap: 12px; }
.req { color: var(--danger); margin-right: 2px; }
.input-inline { display: inline-block; width: 90px; padding: 4px 8px; margin: 0 4px; }
.total { display: flex; justify-content: space-between; align-items: baseline; border-top: 1px solid var(--line); padding-top: 12px; }
.total b { font-size: 1.4rem; color: var(--green); }

/* kreator: zgoda na dane gości */
.consent-gate { display: grid; gap: 14px; justify-items: start; background: var(--card-soft); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 20px; }
.gate-icon { width: 40px; height: 40px; border-radius: 12px; background: var(--fill); color: var(--on-fill); display: grid; place-items: center; }

/* kreator: książeczki */
.fmt.is-disabled { opacity: 0.55; cursor: not-allowed; }
.bk-box { border: 1px solid var(--line); border-radius: 14px; padding: 0 14px; }
.bk-box summary { padding: 13px 2px; cursor: pointer; font-weight: 700; color: var(--ink); font-size: 0.9rem; }
.bk-box[open] { padding-bottom: 14px; display: grid; gap: 12px; }
.bk-box[open] > summary { margin-bottom: -4px; }
.bk-sec { display: grid; gap: 6px; background: var(--card-soft); border-radius: 12px; padding: 10px; }
.bk-sec-head { display: flex; gap: 8px; align-items: center; }
.bk-sec-head .input { padding: 8px 12px; font-weight: 600; }
.bk-sec textarea.input { min-height: 64px; font-size: 0.88rem; padding: 8px 12px; }
.bk-sec .icon-btn, .plan-row .icon-btn { width: 34px; height: 34px; flex: none; color: var(--muted-2); }
.plan-rows { display: grid; gap: 6px; }
.plan-row { display: grid; grid-template-columns: 72px 1fr 34px; gap: 6px; align-items: center; }
.plan-row .input { padding: 8px 10px; font-size: 0.88rem; }
.warn-text { color: var(--amber); font-weight: 600; }
.bk-cloth { padding: clamp(14px, 3vw, 32px); }
.bk-faces { display: grid; gap: 16px; width: 100%; }
.bk-faces.h { grid-template-columns: 1fr; max-width: 520px; }
.bk-faces.v { grid-template-columns: 1fr 1fr; max-width: 560px; }
.bk-faces.t { grid-template-columns: repeat(3, 1fr); max-width: 520px; }
.bk-faces figure { margin: 0; display: grid; gap: 6px; }
.bk-faces figcaption { font-size: 0.75rem; font-weight: 700; color: var(--muted); text-align: center; text-transform: uppercase; letter-spacing: 0.08em; }
.bk-faces .paper, .bk-sheet { width: 100% !important; }
.table-cloth .paper.bk-sheet.h { width: min(100%, 360px) !important; }
.table-cloth .paper.bk-sheet.v { width: min(100%, 560px) !important; }
.table-cloth .paper.bk-sheet.t { width: min(100%, 680px) !important; }
@media (min-width: 1300px) { .bk-faces.h { grid-template-columns: 1fr 1fr; max-width: none; } }
.bk-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-btn { border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 6px 12px; font-size: 0.8rem; font-weight: 600; cursor: pointer; color: var(--ink); }
.chip-btn[aria-pressed="true"] { border-color: var(--fill); background: var(--fill); color: var(--on-fill); }

/* panel admina: zamówienia, kody, system */
.badge-dj { display: inline-block; margin-top: 6px; background: var(--amber-bg-2); color: var(--umber-ink); font-size: 0.7rem; font-weight: 800; padding: 3px 9px; border-radius: 999px; }
.adm-row .money .tiny { display: block; }
.promo-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; align-items: end; margin-bottom: 18px; }
.promo-form .input { padding: 10px 12px; }
.promo-form .check { align-self: center; }
.promo-list { display: grid; gap: 10px; }
.promo-item { display: grid; grid-template-columns: minmax(220px, 1.2fr) 1fr auto; gap: 14px; align-items: center; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.promo-item .actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.promo-item .omni-table, .promo-item .promo-used { grid-column: 1 / -1; }
.omni-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.omni-grid span { background: var(--card-soft); border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; font-size: 0.8rem; display: grid; }
.omni-grid small { color: var(--muted-2); font-size: 0.7rem; }
@media (max-width: 820px) { .promo-item { grid-template-columns: 1fr; } .promo-item .actions { justify-content: flex-start; } }
.switch { display: inline-flex; gap: 8px; align-items: center; cursor: pointer; font-size: 0.85rem; font-weight: 600; color: var(--ink); }
.switch input { appearance: none; -webkit-appearance: none; width: 38px; height: 22px; border-radius: 999px; background: var(--switch-off); position: relative; cursor: pointer; transition: background 0.2s; flex: none; margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25); transition: transform 0.2s var(--ease); }
.switch input:checked { background: var(--fill); }
.switch input:checked::after { transform: translateX(16px); }
.switch input:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.switch-lg { font-size: 1rem; }
.switch-lg input { width: 48px; height: 28px; }
.switch-lg input::after { width: 22px; height: 22px; }
.switch-lg input:checked::after { transform: translateX(20px); }
.hist { display: grid; gap: 6px; font-size: 0.82rem; color: var(--muted); margin-top: 10px; }
.sunset-banner-demo { background: #3a1d0e; color: #fff4e3; border-radius: 12px; padding: 12px 14px; font-size: 0.88rem; }
.danger-zone { border-color: var(--danger-line); }
.danger-zone h3 { color: var(--danger); }

/* konto, regulamin, stopka */
.container.narrow { max-width: 860px; }
.legal h1 { font-size: clamp(1.8rem, 3.6vw, 2.4rem); margin-bottom: 8px; }
.legal h2 { font-size: 1.15rem; margin: 30px 0 10px; }
.legal ol, .legal ul { padding-left: 22px; display: grid; gap: 8px; margin: 0; color: var(--ink); font-size: 0.95rem; }
.legal ul ul { margin-top: 6px; }
.legal p { font-size: 0.95rem; }
.legal-table { margin-top: 6px; }
.contact-table { margin-top: 18px; }
.contact-table th { width: 36%; font-size: 0.85rem; }
.contact-table td { font-size: 0.95rem; overflow-wrap: anywhere; }
.closed-panel p { max-width: 34em; margin-left: auto; margin-right: auto; }
.footer-promo { background: var(--card); border-top: 1px solid var(--line); }
.promo-strip + .footer-promo { margin-top: 0; }
.footer-promo:first-child { margin-top: 40px; }
.footer-promo-inner { display: flex; align-items: center; gap: 14px; padding-top: 16px; padding-bottom: 16px; flex-wrap: wrap; }
.footer-promo-inner > div { flex: 1; min-width: 220px; display: grid; font-size: 0.9rem; }
.footer-promo-inner b { color: var(--green); }
.footer-promo-inner span { color: var(--muted); }
.footer-promo .promo-icon { width: 36px; height: 36px; border-radius: 10px; background: var(--umber); }
.footer-promo .promo-icon svg { width: 19px; height: 19px; }

/* =========================================================
   Podgląd: lupka, powiększenie, widok 3D
   ========================================================= */
.zoomable { cursor: zoom-in; }
.lens { position: fixed; left: 0; top: 0; width: 210px; height: 210px; border-radius: 50%; overflow: hidden; pointer-events: none; z-index: 90; background: #fff; box-shadow: 0 0 0 3px #fff, 0 0 0 4px rgba(0, 77, 64, 0.35), 0 14px 34px rgba(26, 46, 43, 0.3); }
.lens-inner { position: absolute; left: 0; top: 0; line-height: 0; }
.lens-inner svg { width: 100%; height: 100%; display: block; }
.stage-tools { display: flex; gap: 10px 14px; align-items: center; justify-content: center; flex-wrap: wrap; margin-top: 14px; }
.stage-tools .btn svg { flex: none; }
.seg-sm button { padding: 7px 14px; font-size: 0.82rem; }
@media (hover: none), (pointer: coarse) { .lens-hint { display: none; } }

.zoom-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.zoom-tools .icon-btn { font-size: 1.3rem; font-weight: 700; }
.zoom-val { min-width: 48px; text-align: center; }
.zoom-stage { overflow: auto; max-height: calc(100vh - 210px); background: radial-gradient(ellipse at 50% 40%, var(--cloth-a) 0%, var(--cloth-b) 100%); border-radius: var(--radius-md); padding: 18px; -webkit-overflow-scrolling: touch; }
.zoom-content { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 18px; align-items: start; margin: 0 auto; transition: width 0.2s; }
.zoom-item { margin: 0; display: grid; gap: 6px; }
.zoom-item .paper { box-shadow: var(--shadow-paper); background: #fff; line-height: 0; border-radius: 2px; overflow: hidden; }
.zoom-item svg { width: 100%; height: auto; display: block; }
.zoom-item figcaption { font-size: 0.75rem; font-weight: 700; color: var(--muted); text-align: center; text-transform: uppercase; letter-spacing: 0.08em; }

.view3d { display: grid; gap: 10px; justify-items: center; width: 100%; }
.scene3d { position: relative; overflow: hidden; width: 100%; height: calc(var(--h) * 1.45 + 40px); display: grid; place-items: center; perspective: 1500px; perspective-origin: 50% 35%; cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.scene3d.dragging { cursor: grabbing; }
.obj3d { position: relative; width: var(--w); height: var(--h); transform-style: preserve-3d; will-change: transform; }
.leaf { position: absolute; left: 0; top: 0; width: var(--w); height: var(--h); transform-style: preserve-3d; }
.face3d { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; line-height: 0; }
.face3d.out { box-shadow: 0 0 0 0.5px rgba(26, 46, 43, 0.12); }
.face3d.out svg { width: 100%; height: 100%; display: block; }
.face3d.in { transform: rotateY(180deg); background: linear-gradient(180deg, #f6f3ec, #e9e4d8); box-shadow: inset 0 0 0 0.5px rgba(26, 46, 43, 0.12); }
/* namiocik: strony połączone u góry, rozchylone o 2 × 24° */
.tent .obj3d { top: calc(var(--h) * -0.15); }
.tent .leaf { transform-origin: 50% 0; }
.tent .leaf-front { transform: rotateX(24deg); }
.tent .leaf-back { transform: rotateY(180deg) rotateX(24deg); }
/* książeczka: strony połączone pionowo, otwarte jak książka */
.book .obj3d { width: calc(var(--w) * 2); }
.book .leaf-front { left: var(--w); transform-origin: 0 50%; transform: rotateY(38deg); }
.book .leaf-back { left: 0; transform-origin: 100% 50%; transform: rotateY(-38deg); }
/* cień na stole – płaszczyzna pod przedmiotem, obraca się razem z nim */
.floor3d { position: absolute; left: 50%; width: calc(var(--w) * 1.5); height: calc(var(--h) * 1.1); margin-left: calc(var(--w) * -0.75); pointer-events: none;
  background: radial-gradient(closest-side, rgba(26, 46, 43, 0.26), rgba(26, 46, 43, 0.08) 60%, rgba(26, 46, 43, 0)); }
.tent .floor3d { top: calc(var(--h) * (0.913 - 0.55)); transform: rotateX(90deg); }
.book .floor3d { width: calc(var(--w) * 2.2); margin-left: calc(var(--w) * -1.1); height: calc(var(--w) * 1.3); top: calc(var(--h) - var(--w) * 0.65); transform: rotateX(90deg); }
/* totem: trójkątny słupek – trzy ściany obrócone co 120° wokół osi */
.prism .scene3d { height: calc(var(--h) * 1.18 + 40px); }
.prism .leaf { transform-origin: 50% 50%; }
.prism .leaf-p0 { transform: rotateY(0deg) translateZ(var(--a)); }
.prism .leaf-p1 { transform: rotateY(120deg) translateZ(var(--a)); }
.prism .leaf-p2 { transform: rotateY(240deg) translateZ(var(--a)); }
.prism .face3d.in { background: linear-gradient(180deg, #ece8de, #ddd7c8); }
/* lekkie cieniowanie przy krawędziach – słupek wygląda na trójwymiarowy, a nie płaski */
.prism .face3d.out::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(90deg, rgba(26, 46, 43, 0.12), rgba(26, 46, 43, 0) 18%, rgba(26, 46, 43, 0) 82%, rgba(26, 46, 43, 0.1)); }
.prism .floor3d { width: calc(var(--w) * 1.9); margin-left: calc(var(--w) * -0.95); height: calc(var(--w) * 1.9); top: calc(var(--h) - var(--w) * 0.95); transform: rotateX(90deg); }
.rot-tools { display: flex; gap: 12px; align-items: center; }
.table-cloth .view3d { max-width: 100%; }
@media (prefers-reduced-motion: reduce) { .obj3d { transition: none !important; } }
.bk-plain { padding: 14px; display: grid; gap: 12px; }
.bk-plain h5 { margin: 0; font-size: 0.9rem; color: var(--ink); }

/* strona startowa: winietka 3D w nagłówku i przycisk „3D” w galerii */
.hero-3d { display: grid; justify-items: center; gap: 6px; background: radial-gradient(ellipse at 50% 45%, var(--cloth-a) 0%, var(--cloth-b) 72%, var(--cloth-fade) 100%); border-radius: var(--radius-lg); padding: 6px 0 14px; }
.hero-3d #hero-3d { width: 100%; }
.hero-pick { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.rot-hint { margin-top: -6px; }
.btn-3d { position: absolute; top: 8px; right: 8px; border: 0; background: var(--glass-chip); color: var(--green); font-weight: 800; font-size: 0.72rem; letter-spacing: 0.04em; padding: 5px 10px; border-radius: 999px; cursor: pointer; box-shadow: 0 1px 4px rgba(26, 46, 43, 0.18); transition: background 0.2s, color 0.2s; }
.btn-3d:hover, .btn-3d:focus-visible { background: var(--fill); color: var(--on-fill); }
@media (max-width: 900px) { .hero-3d { max-width: 520px; width: 100%; margin: 10px auto 0; } }

/* znak wodny na podglądzie i informacja o fikcyjnych danych */
.wm-note { display: flex; gap: 10px; align-items: flex-start; margin: 12px auto 0; max-width: 620px; font-size: 0.82rem; color: var(--warn-ink); background: var(--amber-bg); border-radius: 12px; padding: 10px 14px; }
.wm-note svg { flex: none; width: 18px; height: 18px; margin-top: 1px; }
.fict { font-size: 0.74rem; color: var(--muted-2); text-align: center; margin: 4px 12px 0; font-style: italic; }
.booklet-show .fict { margin-top: -4px; }

/* faktura: przełącznik w formularzu i znacznik w panelu admina */
.buyer-field .choice-row { margin-bottom: 2px; }
.ksef-note { background: var(--card-soft); border-radius: 10px; padding: 10px 12px; color: var(--ink); }
.inv-chip { display: inline-block; margin-top: 6px; border: 1px solid var(--line); background: var(--card); color: var(--green); font-weight: 700; font-size: 0.72rem; padding: 4px 10px; border-radius: 999px; cursor: pointer; }
.inv-chip.todo { background: var(--amber-bg); color: var(--amber); border-color: var(--amber-line); }
.inv-chip.done { background: var(--ok-bg); color: var(--ok); border-color: transparent; }

/* ---------- limit pobrań PDF ---------- */
.dl-meter { border: 2px solid var(--green); border-radius: 14px; padding: 14px 16px; display: grid; gap: 10px; background: var(--green-tint); }
.dl-meter .small { color: var(--ink); margin: 0; }
.dl-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.dl-lead { font-weight: 700; color: var(--green); font-size: 1rem; }
.dl-num { font-size: 2rem; line-height: 1; font-weight: 800; color: var(--green); letter-spacing: -0.01em; font-variant-numeric: tabular-nums; }
.dl-what { font-size: 0.84rem; color: var(--muted); }
.dl-pips { display: flex; flex-wrap: wrap; gap: 5px; }
.dl-pips i { width: 18px; height: 8px; border-radius: 4px; background: var(--pip-off); }
.dl-pips i.on { background: var(--green); }
.dl-meter.dl-low { border-color: var(--amber); background: var(--amber-bg); }
.dl-meter.dl-low .dl-lead, .dl-meter.dl-low .dl-num { color: var(--amber); }
.dl-meter.dl-low .dl-pips i.on { background: var(--amber); }
.dl-meter.dl-empty { border-color: var(--empty-line); background: var(--empty-bg); }
.dl-meter.dl-empty .dl-lead, .dl-meter.dl-empty .dl-num { color: var(--muted-2); }
.dl-meter.dl-admin { border-style: dashed; border-width: 1px; background: transparent; }
.btn.is-spent, .btn.is-spent:hover { background: var(--spent-bg) !important; border-color: var(--spent-bg) !important; color: var(--spent-ink) !important; box-shadow: none !important; cursor: not-allowed; }
.dl-line { display: inline-block; }
.dl-line-empty b { color: var(--danger); }

/* ---------- dane do płatności: przelew ALBO BLIK – zawsze jedno pod drugim ---------- */
.pay-box { min-width: 0; }
.pay-sum { display: flex; flex-wrap: wrap; gap: 10px 28px; align-items: flex-end; margin-top: 12px; }
.pay-sum > div { display: grid; gap: 2px; min-width: 0; }
.pay-label { font-size: 0.78rem; color: var(--muted); }
.pay-value { font-weight: 700; font-size: 1.05rem; color: var(--ink); font-variant-numeric: tabular-nums; }
.pay-copy { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pay-methods { display: grid; gap: 10px; margin-top: 14px; }
.pay-method { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; background: var(--card); display: grid; gap: 10px; min-width: 0; }
.pay-method h5 { margin: 0; font-size: 0.82rem; color: var(--green); text-transform: uppercase; letter-spacing: 0.05em; display: flex; align-items: center; gap: 8px; }
.pay-method h5 .num { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--fill); color: var(--on-fill); font-size: 0.75rem; letter-spacing: 0; }
.pay-field { display: grid; gap: 2px; min-width: 0; }
.pay-field .pay-value { overflow-wrap: anywhere; word-break: normal; }
.pay-or { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 0.78rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.08em; }
.pay-or::before, .pay-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.pay-hint { font-size: 0.8rem; color: var(--muted); margin: 0; }

/* =========================================================
   TRYB CIEMNY – według ustawień systemu albo przełącznika w nagłówku (data-theme).
   Podglądy winietek i książeczek zostają białe – to papier.
   ========================================================= */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --green: #7fd3bf;
    --green-dark: #a6e3d4;
    --green-tint: rgba(127, 211, 191, 0.12);
    --cream: #1d2a27;
    --umber: #4a3210;
    --ink: #e4ecea;
    --muted: #a7b6b3;
    --muted-2: #8b9c99;
    --line: #2b3936;
    --card: #15201e;
    --card-soft: #192624;
    --amber: #f2c46b;
    --amber-bg: #2d2414;
    --ok: #7fd9b0;
    --ok-bg: #12302a;
    --danger: #ff97a8;
    --danger-bg: #3a1a21;
    --shadow-card: 0 15px 30px rgba(0, 0, 0, 0.35);
    --shadow-paper: 0 1px 2px rgba(0, 0, 0, 0.45), 0 14px 34px rgba(0, 0, 0, 0.55);
    --bg: #0e1614;
    --input-bg: #101a18;
    --line-strong: #3a4a46;
    --line-soft: #22302d;
    --line-warm: #33413d;
    --fill: #1f7a69;
    --fill-hover: #2a9a85;
    --on-fill: #ffffff;
    --umber-ink: #e9c58c;
    --footer-bg: #0a2b25;
    --warn-ink: #f3dcae;
    --ok-ink: #c2efdd;
    --err-ink: #ffc4ce;
    --danger-line: #5c2a33;
    --danger-fill: #b3203d;
    --amber-bg-2: #2d2414;
    --amber-line: #5a4520;
    --neutral-bg: #252f2d;
    --neutral-ink: #a9b3b0;
    --glass: rgba(14, 22, 20, 0.86);
    --glass-strong: rgba(14, 22, 20, 0.97);
    --glass-card: rgba(21, 32, 30, 0.88);
    --glass-chip: rgba(21, 32, 30, 0.92);
    --cloth-a: #1e2a28;
    --cloth-b: #131c1a;
    --cloth-fade: rgba(19, 28, 26, 0);
    --focus: rgba(127, 211, 191, 0.5);
    --focus-soft: rgba(127, 211, 191, 0.18);
    --switch-off: #3a4a46;
    --pip-off: rgba(228, 236, 234, 0.16);
    --empty-bg: #1b2422;
    --empty-line: #3a4643;
    --spent-bg: #28312f;
    --spent-ink: #7f8d8a;
    --toast-bg: #2c433e;
    --mark-bg: rgba(255, 214, 0, 0.28);
    --modal-backdrop: rgba(0, 0, 0, 0.6);
    --bg-photo-opacity: 0.1;
    --g-bg: #131314;
    --g-ink: #e3e3e3;
    --g-line: #8e918f;
    --g-hover-bg: #1f1f20;
    --g-hover-line: #a8aba9;
  }
  :root:not([data-theme="light"]) #brand-logo { filter: invert(1) hue-rotate(180deg); }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --green: #7fd3bf;
  --green-dark: #a6e3d4;
  --green-tint: rgba(127, 211, 191, 0.12);
  --cream: #1d2a27;
  --umber: #4a3210;
  --ink: #e4ecea;
  --muted: #a7b6b3;
  --muted-2: #8b9c99;
  --line: #2b3936;
  --card: #15201e;
  --card-soft: #192624;
  --amber: #f2c46b;
  --amber-bg: #2d2414;
  --ok: #7fd9b0;
  --ok-bg: #12302a;
  --danger: #ff97a8;
  --danger-bg: #3a1a21;
  --shadow-card: 0 15px 30px rgba(0, 0, 0, 0.35);
  --shadow-paper: 0 1px 2px rgba(0, 0, 0, 0.45), 0 14px 34px rgba(0, 0, 0, 0.55);
  --bg: #0e1614;
  --input-bg: #101a18;
  --line-strong: #3a4a46;
  --line-soft: #22302d;
  --line-warm: #33413d;
  --fill: #1f7a69;
  --fill-hover: #2a9a85;
  --on-fill: #ffffff;
  --umber-ink: #e9c58c;
  --footer-bg: #0a2b25;
  --warn-ink: #f3dcae;
  --ok-ink: #c2efdd;
  --err-ink: #ffc4ce;
  --danger-line: #5c2a33;
  --danger-fill: #b3203d;
  --amber-bg-2: #2d2414;
  --amber-line: #5a4520;
  --neutral-bg: #252f2d;
  --neutral-ink: #a9b3b0;
  --glass: rgba(14, 22, 20, 0.86);
  --glass-strong: rgba(14, 22, 20, 0.97);
  --glass-card: rgba(21, 32, 30, 0.88);
  --glass-chip: rgba(21, 32, 30, 0.92);
  --cloth-a: #1e2a28;
  --cloth-b: #131c1a;
  --cloth-fade: rgba(19, 28, 26, 0);
  --focus: rgba(127, 211, 191, 0.5);
  --focus-soft: rgba(127, 211, 191, 0.18);
  --switch-off: #3a4a46;
  --pip-off: rgba(228, 236, 234, 0.16);
  --empty-bg: #1b2422;
  --empty-line: #3a4643;
  --spent-bg: #28312f;
  --spent-ink: #7f8d8a;
  --toast-bg: #2c433e;
  --mark-bg: rgba(255, 214, 0, 0.28);
  --modal-backdrop: rgba(0, 0, 0, 0.6);
  --bg-photo-opacity: 0.1;
  --g-bg: #131314;
  --g-ink: #e3e3e3;
  --g-line: #8e918f;
  --g-hover-bg: #1f1f20;
  --g-hover-line: #a8aba9;
}
:root[data-theme="dark"] #brand-logo { filter: invert(1) hue-rotate(180deg); }

/* przełącznik motywu w nagłówku */
.theme-toggle { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--ink); display: grid; place-items: center; cursor: pointer; transition: border-color 0.2s, color 0.2s; }
.theme-toggle:hover { border-color: var(--green); color: var(--green); }
.theme-toggle svg { width: 19px; height: 19px; }
@media (max-width: 920px) { .theme-toggle { width: 44px; height: 44px; border-radius: 12px; } }

/* ---------- admin: dane do faktury w wierszu, szczegóły zamówienia ---------- */
button.code-link { background: none; border: 0; padding: 0; cursor: pointer; font-size: inherit; text-decoration: underline dotted; text-underline-offset: 3px; }
button.code-link:hover { text-decoration-style: solid; }
.buyer-box { display: grid; gap: 1px; margin-top: 8px; padding: 8px 10px; border-radius: 10px; background: var(--card); border: 1px solid var(--line); font-size: 0.8rem; color: var(--ink); word-break: break-word; }
.buyer-box .tiny { color: var(--green); font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
.buyer-box.is-company { border-color: var(--amber-line); }
.details-list { grid-template-columns: minmax(150px, auto) 1fr; align-items: start; }
.details-list dd { font-weight: 500; white-space: pre-line; }
@media (max-width: 560px) { .details-list { grid-template-columns: 1fr; gap: 2px; } .details-list dd { margin-bottom: 8px; } }
.pkg-option small.pkg-per { font-size: 0.68rem; opacity: 0.85; text-align: center; line-height: 1.25; margin-top: 2px; }

/* książeczka 4-stronicowa: wnętrze w 3D, dwa arkusze, cztery strony */
.face3d.in.has-art { background: #fff; }
.face3d.in.has-art svg { width: 100%; height: 100%; display: block; }
.bk-sheets { display: grid; gap: 14px; width: 100%; justify-items: center; }
.bk-sheets figure { margin: 0; display: grid; gap: 6px; justify-items: center; width: 100%; }
.bk-sheets figcaption { font-size: 0.75rem; color: var(--muted); text-align: center; }
.bk-faces.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* ustawienia druku: tło i papier */
.paper-swatches .swatch { border: 1px solid var(--line-strong); }
.print-opts .check { align-items: flex-start; }

/* admin: grupy szablonów (kolekcja 2027) */
.tpl-group-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.tpl-admin .tpl-state { display: block; margin-top: 2px; }

/* ---------- płatności online Przelewy24 ---------- */
.btn-pay { gap: 8px; }
.btn-pay svg { flex: none; }
.pay-cta { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: center; }
.pay-cta .pay-note { flex-basis: 100%; margin: 0; }
.pay-note b { color: var(--ink); }
.pay-result .hero-actions { justify-content: center; }
.pay-wait { display: grid; place-items: center; margin-bottom: 16px; }
.spin-lg { width: 44px; height: 44px; border: 4px solid var(--green); border-right-color: transparent; border-radius: 50%; animation: spin 0.8s linear infinite; display: block; }
.chip-p24 { background: var(--green-tint); color: var(--green); margin-left: 4px; }
.chip-p24::before { display: none; }
.chip-p24.is-test { background: var(--amber-bg); color: var(--amber); }
.wait-online { display: block; margin-bottom: 6px; }
.p24-issue { grid-column: 1 / -1; display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; background: var(--danger-bg); color: var(--err-ink); border: 1px solid var(--danger-line); border-radius: 10px; padding: 10px 14px; font-size: 0.88rem; }
.p24-switch { align-items: flex-start; }
.p24-switch input { margin-top: 3px; }
.sess-table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
.sess-table th { text-align: left; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted-2); padding: 6px 8px; border-bottom: 1px solid var(--line); }
.sess-table td { padding: 8px; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
.sess-table tr.has-issue td { background: var(--danger-bg); }
.sess { font-weight: 700; }
.sess-paid { color: var(--ok); }
.sess-started, .sess-registering { color: var(--muted); font-weight: 600; }
.sess-error, .sess-mismatch { color: var(--danger); }
.demo-gw { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--card-soft); }
.demo-gw > div { display: grid; gap: 2px; min-width: 0; }
.demo-gw b { overflow-wrap: anywhere; }
.demo-gw-amount { font-size: 1.25rem; color: var(--green); }
.demo-gw-methods { display: flex; flex-wrap: wrap; gap: 8px; }
.demo-gw-methods span { border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; font-size: 0.82rem; font-weight: 700; color: var(--muted); background: var(--card); }
@media (max-width: 560px) {
  .demo-gw { grid-template-columns: 1fr; }
  .pay-cta .btn { width: 100%; justify-content: center; }
}

/* ---------- logotypy Przelewy24 / BLIK / Visa / Mastercard (oficjalne pliki z assets/p24) ---------- */
.pay-logos { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; vertical-align: middle; }
.pl { display: inline-flex; align-items: center; justify-content: center; height: 30px; padding: 0 8px; background: #fff; border: 1px solid #e3e3e3; border-radius: 6px; }
.pl img { display: block; height: 17px; width: auto; }
.pl-p24 img { height: 24px; }
.pay-logos-sm .pl { height: 24px; padding: 0 6px; }
.pay-logos-sm .pl img { height: 13px; }
.pay-logos-sm .pl-p24 img { height: 19px; }
.pay-note { display: grid; gap: 6px; }
.pay-note p { margin: 0; }
.pay-cta .pay-note { flex-basis: 100%; }
.pricing-pay { display: flex; margin-top: 14px; }
.footer-pay { display: inline-flex; align-items: center; gap: 8px; }
.footer-pay .pl { height: 28px; }
.footer-pay .pl-p24 img { height: 22px; }
