/* ═══════════════════════════════════════════════════════════════════════════
   AiRender — strony kampanii /promo i /cad-decor-pro (paczki 581, 598)
   Ciemna, „kampanijna”: wielki nagłówek, zdjęcie na całą szerokość, białe
   przyciski-pigułki, karty pakietów, FAQ. Wszystko pod .bf, żeby nie ruszać
   reszty serwisu (nagłówek i stopka z site.css/site.js zostają bez zmian).
   Treść akcji (kod, bonus, data końca) ustawia się w /static/oferta.js.
   ═══════════════════════════════════════════════════════════════════════ */

.bf {
  --bf-bg: #0a0a0b;
  --bf-bg2: #131316;
  --bf-line: #26262b;
  --bf-text: #f4f4f5;
  --bf-muted: #a1a1aa;
  --bf-acc: #9a6cff;
  --bf-acc2: #c4b5fd;
  background: var(--bf-bg);
  color: var(--bf-text);
  font-family: 'Inter Tight', 'Segoe UI', system-ui, sans-serif;
  overflow-x: clip;
}
.bf h1, .bf h2, .bf h3 { font-weight: 700; letter-spacing: -0.035em; line-height: 0.98; margin: 0; }
.bf p { margin: 0; }
.bf code { font-family: inherit; font-weight: 700; color: #fff; background: rgba(154,108,255,.18);
           border: 1px dashed rgba(196,181,253,.6); border-radius: 6px; padding: 1px 7px; }
.bf a { color: inherit; }

.bf-eyebrow { font-size: 14px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--bf-acc2); margin-bottom: 18px !important; }

/* ── pasek akcji ── */
.bf-strip { display: flex; gap: 18px; justify-content: center; align-items: center; flex-wrap: wrap;
  padding: 10px 16px; font-size: 14px; background: linear-gradient(90deg, #2a1259, #5b21b6 50%, #2a1259); }
.bf-strip a { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.bf-strip code { background: rgba(0,0,0,.25); }

/* ── hero ── */
.bf-hero { position: relative; min-height: min(92vh, 900px); display: flex; align-items: flex-end; isolation: isolate; overflow: hidden; }
.bf-hero-bg { position: absolute; inset: 0; z-index: -2; overflow: hidden; }
.bf-hero-media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; max-width: none; will-change: transform; transform-origin: 50% 30%; }
.bf-hero-bg { animation: bf-zoom 2.4s cubic-bezier(.2,.7,.1,1) both; }
.bf-hero::after { content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(10,10,11,.15) 0%, rgba(10,10,11,.35) 40%, rgba(10,10,11,.96) 92%),
              linear-gradient(90deg, rgba(10,10,11,.75) 0%, rgba(10,10,11,0) 65%); }
@keyframes bf-zoom { from { transform: scale(1.18); filter: brightness(.4) blur(6px); } to { transform: scale(1); filter: none; } }
.bf-scroll { position: absolute; left: 50%; bottom: 22px; width: 26px; height: 42px; margin-left: -13px; border: 2px solid rgba(255,255,255,.45); border-radius: 14px; }
.bf-scroll::after { content: ""; position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: #fff; animation: bf-kolko 1.8s ease-in-out infinite; }
@keyframes bf-kolko { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* ── wejście: nagłówek słowo po słowie, reszta hero po kolei ── */
.bf-w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.bf-w > span { display: inline-block; transform: translateY(105%); transition: transform 1s cubic-bezier(.16,1,.3,1); transition-delay: calc(var(--i) * 70ms + 250ms); }
.bf-start .bf-w > span { transform: none; }
.bf-in { opacity: 0; transform: translateY(24px); transition: opacity .9s ease, transform .9s cubic-bezier(.16,1,.3,1); transition-delay: calc(var(--i) * 70ms + 300ms); }
.bf-start .bf-in { opacity: 1; transform: none; }

/* ── wejście przy przewijaniu ── */
.rv { opacity: 0; transform: translateY(48px); transition: opacity 1s ease, transform 1.1s cubic-bezier(.16,1,.3,1); transition-delay: var(--d, 0ms); }
.rv.in { opacity: 1; transform: none; }
.bf-mask { overflow: hidden; border-radius: 16px; clip-path: inset(14% 8% 14% 8% round 24px); transition: clip-path 1.4s cubic-bezier(.16,1,.3,1) .1s; }
.rv.in .bf-mask, .bf-mask.rv.in { clip-path: inset(0 0 0 0 round 16px); }
.bf-mask img { transition: transform 1.6s cubic-bezier(.16,1,.3,1); }

/* ── manifest: słowa rozjaśniają się przy przewijaniu ── */
.bf-manifest { max-width: 1100px; }
.bf-manifest p { font-size: clamp(2rem, 4.6vw, 4rem); font-weight: 600; line-height: 1.12; letter-spacing: -0.03em; }
.bf-manifest span { color: #3f3f46; transition: color .35s ease; }
.bf-manifest span.on { color: var(--bf-text); }

/* ── galeria w dwóch rzędach ── */
.bf-reel { padding-top: 110px; display: grid; gap: 16px; overflow: hidden; }
.bf-reel-track { display: flex; gap: 16px; width: max-content; animation: bf-marq 60s linear infinite; }
.bf-rev .bf-reel-track { animation-direction: reverse; animation-duration: 70s; }
.bf-reel:hover .bf-reel-track { animation-play-state: paused; }
.bf-reel img { height: clamp(180px, 26vw, 340px); width: auto; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 14px; max-width: none; transition: transform .5s ease, filter .5s ease; }
.bf-reel img:hover { transform: scale(1.03); filter: brightness(1.1); }

/* ── licznik: cyfra podskakuje przy zmianie ── */
.bf-count b.tik { animation: bf-tik .45s cubic-bezier(.16,1,.3,1); }
@keyframes bf-tik { from { transform: translateY(-35%); opacity: .2; } to { transform: none; opacity: 1; } }

/* ── przycisk: przebłysk ── */
.bf-btn { position: relative; overflow: hidden; }
.bf-btn-white::after { content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(124,58,237,.25), transparent); transform: skewX(-20deg); transition: left .7s ease; }
.bf-btn-white:hover::after { left: 120%; }

/* ── karta: światło za kursorem ── */
.bf-card::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s;
  background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), rgba(154,108,255,.18), transparent 60%); }
.bf-card:hover::before { opacity: 1; }
.bf-card { transition: opacity 1s ease, transform 1.1s cubic-bezier(.16,1,.3,1), border-color .3s; }
.bf-card.in:hover { transform: translateY(-6px); transition-delay: 0ms; }

.bf { min-height: 100vh; }
.bf-hero-in { width: 100%; max-width: 1240px; margin: 0 auto; padding: 120px 32px 64px; }
.bf-hero h1 { font-size: clamp(3rem, 9vw, 8.5rem); max-width: 12ch; }
.bf-lead { max-width: 560px; margin-top: 26px !important; font-size: clamp(1.05rem, 1.6vw, 1.25rem); line-height: 1.5; color: #e4e4e7; }
.bf-cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 32px; }
.bf-micro { margin-top: 16px !important; font-size: 13px; color: var(--bf-muted); }
.bf-micro a { text-decoration: underline; }

.bf-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 28px;
  border-radius: 999px; font-weight: 600; font-size: 16px; text-decoration: none; transition: transform .15s, background .15s, border-color .15s; }
.bf-btn:hover { transform: translateY(-1px); text-decoration: none; }
.bf-btn-white { background: #fff; color: #0a0a0b !important; }
.bf-btn-white:hover { background: #e9e3ff; }
.bf-btn-line { border: 1px solid rgba(255,255,255,.35); color: #fff; background: rgba(10,10,11,.25); backdrop-filter: blur(6px); }
.bf-btn-line:hover { border-color: #fff; }

.bf-count { display: flex; gap: 10px; margin-top: 40px; }
.bf-count div { min-width: 74px; padding: 10px 12px; border: 1px solid rgba(255,255,255,.14); border-radius: 12px;
  background: rgba(10,10,11,.45); backdrop-filter: blur(8px); text-align: center; }
.bf-count b { display: block; font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.bf-count span { font-size: 12px; color: var(--bf-muted); }
.bf-count[hidden] { display: none; }

/* ── marquee ── */
.bf-marquee { border-block: 1px solid var(--bf-line); overflow: hidden; padding: 18px 0; }
.bf-marquee-track { display: flex; width: max-content; animation: bf-marq 40s linear infinite; }
.bf-marquee span { font-size: clamp(1.2rem, 2.4vw, 1.9rem); font-weight: 600; letter-spacing: -0.02em; color: #d4d4d8; padding: 0 28px; white-space: nowrap; }
.bf-marquee span::after { content: "✦"; color: var(--bf-acc); margin-left: 56px; font-size: .7em; vertical-align: middle; }
@keyframes bf-marq { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .bf-marquee-track, .bf-reel-track, .bf-hero-bg, .bf-scroll::after, .bf-btn-duzy { animation: none; }
  .bf-w > span, .bf-in, .rv { transform: none; opacity: 1; transition: none; }
  .bf-mask { clip-path: none; }
  .bf-manifest span { color: var(--bf-text); }
}

/* ── sekcje ── */
.bf-sec { max-width: 1240px; margin: 0 auto; padding: 110px 32px 0; }
.bf-head { max-width: 760px; margin-bottom: 48px; }
.bf-head h2, .bf-faq h2, .bf-final h2 { font-size: clamp(2.4rem, 6vw, 5rem); }
.bf-head > p:last-child { margin-top: 22px; font-size: 1.15rem; line-height: 1.55; color: var(--bf-muted); }

/* ── przed/po ── */
.bf-ba.bf-mask { position: relative; }
.bf-ba { position: relative; aspect-ratio: 1313 / 800; border-radius: 20px; overflow: hidden; background: #000; --pos: 50%; user-select: none; }
.bf-ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; max-width: none; }
.bf-ba-before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.bf-ba input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; margin: 0; }
.bf-ba-handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; background: #fff; pointer-events: none; transform: translateX(-1px); }
.bf-ba-handle::after { content: "⟷"; position: absolute; top: 50%; left: 50%; width: 48px; height: 48px; transform: translate(-50%, -50%);
  border-radius: 50%; background: #fff; color: #0a0a0b; display: grid; place-items: center; font-size: 20px; font-weight: 700; }
.bf-ba-tag { position: absolute; top: 16px; padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 600;
  background: rgba(10,10,11,.6); backdrop-filter: blur(6px); pointer-events: none; }
.bf-ba-tag.l { left: 16px; } .bf-ba-tag.r { right: 16px; }

/* ── karty pakietów ── */
.bf-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.bf-card { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 28px 24px 24px;
  border: 1px solid var(--bf-line); border-radius: 20px; background: var(--bf-bg2); }
.bf-card.pop { border-color: var(--bf-acc); background: linear-gradient(180deg, rgba(124,58,237,.22), var(--bf-bg2) 55%); }
.bf-card-badge { position: absolute; top: -12px; left: 24px; padding: 4px 12px; border-radius: 999px; background: var(--bf-acc); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: .04em; }
.bf-card h3 { font-size: 1.5rem; letter-spacing: -0.02em; }
.bf-card-save { color: var(--bf-acc2); font-size: 14px; font-weight: 600; min-height: 20px; }
.bf-card-price { margin-top: 14px !important; font-size: 3rem; font-weight: 700; letter-spacing: -0.04em; line-height: 1; }
.bf-card-price small { font-size: 1rem; font-weight: 500; color: var(--bf-muted); letter-spacing: 0; }
.bf-card-cred { font-size: 15px; color: #e4e4e7; }
.bf-card-cred s { color: var(--bf-muted); }
.bf-card ul { list-style: none; margin: 14px 0 22px; padding: 14px 0 0; border-top: 1px solid var(--bf-line); display: grid; gap: 8px; font-size: 14px; color: var(--bf-muted); }
.bf-card li::before { content: "✓"; color: var(--bf-acc2); margin-right: 8px; }
.bf-card .bf-btn { margin-top: auto; min-height: 46px; }
.bf-card:not(.pop) .bf-btn { background: transparent; color: #fff !important; border: 1px solid rgba(255,255,255,.3); }
.bf-card:not(.pop) .bf-btn:hover { border-color: #fff; }
.bf-note { margin-top: 18px !important; font-size: 13px; color: var(--bf-muted); }

/* ── bloki funkcji ── */
.bf-feats { display: grid; gap: 22px; }
.bf-feat { display: grid; grid-template-columns: 1fr 1.25fr; align-items: center; gap: 48px; padding: 28px;
  border: 1px solid var(--bf-line); border-radius: 24px; background: var(--bf-bg2); }
.bf-feat-rev { grid-template-columns: 1.25fr 1fr; }
.bf-feat-rev .bf-feat-txt { order: 2; }
.bf-feat h3 { font-size: clamp(2rem, 4vw, 3.4rem); }
.bf-feat-txt > p:last-child { margin-top: 18px; color: var(--bf-muted); font-size: 1.05rem; line-height: 1.55; max-width: 420px; }
.bf-feat .bf-mask { aspect-ratio: 16 / 10; }
.bf-feat img { width: 100%; height: 100%; object-fit: cover; max-width: none; }

/* ── FAQ ── */
.bf-faq { max-width: 900px; }
.bf-faq h2 { margin-bottom: 36px; }
.bf-faq details { border-top: 1px solid var(--bf-line); }
.bf-faq details:last-of-type { border-bottom: 1px solid var(--bf-line); }
.bf-faq summary { list-style: none; cursor: pointer; padding: 22px 40px 22px 0; position: relative; font-size: 1.2rem; font-weight: 600; letter-spacing: -0.01em; }
.bf-faq summary::-webkit-details-marker { display: none; }
.bf-faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 28px; font-weight: 400; color: var(--bf-muted); transition: transform .2s; }
.bf-faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.bf-faq details p { padding: 0 40px 22px 0; color: var(--bf-muted); line-height: 1.6; }
.bf-faq details a { text-decoration: underline; }

/* ── zamknięcie ── */
.bf-final .rv:nth-child(2) { --d: 100ms; } .bf-final .rv:nth-child(3) { --d: 200ms; }
.bf-final { max-width: 1240px; margin: 110px auto 0; padding: 100px 32px; text-align: center; border-top: 1px solid var(--bf-line);
  background: radial-gradient(ellipse 60% 70% at 50% 100%, rgba(124,58,237,.35), transparent 70%); }
.bf-final h2 { margin-bottom: 34px; }
.bf-terms { max-width: 640px; margin: 30px auto 0 !important; font-size: 12.5px; line-height: 1.6; color: #71717a; }
.bf-terms a { text-decoration: underline; }

/* ── załóż konto ── */
.bf-konto-in { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; padding: 56px;
  border-radius: 28px; border: 1px solid rgba(154,108,255,.45);
  background: radial-gradient(ellipse 80% 120% at 0% 0%, rgba(124,58,237,.38), transparent 60%), var(--bf-bg2); }
.bf-konto h2 { font-size: clamp(2.3rem, 5vw, 4.2rem); }
.bf-konto-txt > p:not(.bf-eyebrow):not(.bf-konto-zalety) { margin: 22px 0 30px !important; font-size: 1.15rem; line-height: 1.55; color: #d4d4d8; max-width: 520px; }
.bf-btn-duzy { min-height: 60px; padding: 0 36px; font-size: 18px; box-shadow: 0 0 0 0 rgba(154,108,255,.6); animation: bf-puls 2.6s ease-out infinite; }
@keyframes bf-puls { 0% { box-shadow: 0 0 0 0 rgba(154,108,255,.55); } 70%, 100% { box-shadow: 0 0 0 18px rgba(154,108,255,0); } }
.bf-konto-zalety { margin-top: 16px !important; font-size: 13px; color: var(--bf-muted); }
.bf-kroki { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.bf-kroki li { display: flex; gap: 18px; align-items: flex-start; padding: 20px 22px; border-radius: 18px; background: rgba(10,10,11,.55); border: 1px solid var(--bf-line); }
.bf-kroki b { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: #0a0a0b; font-size: 18px; }
.bf-kroki h3 { font-size: 1.25rem; letter-spacing: -0.02em; line-height: 1.2; }
.bf-kroki p { margin-top: 4px !important; color: var(--bf-muted); font-size: 15px; line-height: 1.5; }

/* ── pasek z przyciskiem na dole ekranu ── */
.bf-lepki { position: fixed; left: 50%; bottom: 18px; z-index: 90; display: flex; align-items: center; gap: 18px;
  padding: 8px 8px 8px 22px; border-radius: 999px; background: rgba(19,19,22,.88); backdrop-filter: blur(14px);
  border: 1px solid rgba(154,108,255,.45); box-shadow: 0 12px 40px rgba(0,0,0,.5);
  transform: translate(-50%, 140%); opacity: 0; pointer-events: none; transition: transform .5s cubic-bezier(.16,1,.3,1), opacity .4s; max-width: calc(100% - 32px); }
.bf-lepki.on { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
.bf-lepki span { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bf-lepki .bf-btn { min-height: 44px; padding: 0 22px; font-size: 15px; flex: none; }

/* ── współpraca z programem: most + kafle (paczka 598, /cad-decor-pro) ── */
.bf-most { display: flex; align-items: center; gap: 0; margin: 0 0 40px; }
.bf-most-k { flex: none; padding: 16px 26px; border-radius: 999px; border: 1px solid var(--bf-line); background: var(--bf-bg2);
  font-weight: 700; font-size: clamp(1rem, 2vw, 1.35rem); letter-spacing: -0.02em; white-space: nowrap; }
.bf-most-ar { background: #fff; color: #0a0a0b; border-color: #fff; box-shadow: 0 0 60px rgba(154,108,255,.45); }
.bf-most-tory { flex: 1; min-width: 60px; display: grid; gap: 30px; padding: 0 6px; }
.bf-most-tor { position: relative; height: 2px; background: linear-gradient(90deg, var(--bf-line), rgba(154,108,255,.6), var(--bf-line)); }
.bf-most-tor em { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); font-style: normal; font-size: 13px;
  font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--bf-muted); white-space: nowrap; }
.bf-most-tor.bf-wstecz em { bottom: auto; top: 10px; }
.bf-most-tor i { position: absolute; top: -4px; left: 0; width: 10px; height: 10px; border-radius: 50%; background: var(--bf-acc2);
  box-shadow: 0 0 14px var(--bf-acc); animation: bf-tam 3s linear infinite; opacity: 0; }
.bf-most-tor i:nth-of-type(2) { animation-delay: 1s; } .bf-most-tor i:nth-of-type(3) { animation-delay: 2s; }
.bf-most-tor.bf-wstecz i { animation-name: bf-wstecz; background: #fff; }
@keyframes bf-tam { 0% { left: 0; opacity: 0; } 10%, 90% { opacity: 1; } 100% { left: calc(100% - 10px); opacity: 0; } }
@keyframes bf-wstecz { 0% { left: calc(100% - 10px); opacity: 0; } 10%, 90% { opacity: 1; } 100% { left: 0; opacity: 0; } }
.bf-kafle { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.bf-kafel { position: relative; padding: 28px 26px; border-radius: 20px; background: var(--bf-bg2); border: 1px solid var(--bf-line);
  transition: opacity 1s ease, transform 1.1s cubic-bezier(.16,1,.3,1), border-color .3s, background .3s; transition-delay: var(--d, 0ms); }
.bf-kafel.in:hover { border-color: rgba(154,108,255,.6); background: linear-gradient(180deg, rgba(124,58,237,.16), var(--bf-bg2) 70%); transform: translateY(-4px); transition-delay: 0ms; }
.bf-kafel-i { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px; background: rgba(154,108,255,.14);
  border: 1px solid rgba(154,108,255,.35); font-size: 26px; margin-bottom: 18px; }
.bf-kafel h3 { font-size: 1.45rem; letter-spacing: -0.02em; line-height: 1.1; }
.bf-kafel p { margin-top: 10px !important; color: var(--bf-muted); font-size: 15px; line-height: 1.55; }
@media (max-width: 1000px) { .bf-kafle { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 800px) {
  .bf-kafle { grid-template-columns: 1fr; }
  .bf-most-k { padding: 12px 16px; }
  .bf-most-tor em { font-size: 10px; letter-spacing: .04em; }
}
@media (prefers-reduced-motion: reduce) { .bf-most-tor i { animation: none; opacity: 0; } }

/* ── telefon ── */
@media (max-width: 800px) {
  .bf-hero-in, .bf-sec { padding-left: 16px; padding-right: 16px; }
  .bf-sec { padding-top: 80px; }
  .bf-hero { min-height: 88vh; }
  .bf-count div { min-width: 0; flex: 1; padding: 8px 4px; }
  .bf-count b { font-size: 24px; }
  .bf-feat, .bf-feat-rev { grid-template-columns: 1fr; gap: 22px; padding: 18px; }
  .bf-feat-rev .bf-feat-txt { order: 0; }
  .bf-ba { aspect-ratio: 4 / 3; }
  .bf-final .rv:nth-child(2) { --d: 100ms; } .bf-final .rv:nth-child(3) { --d: 200ms; }
.bf-final { padding: 80px 16px; }
  .bf-strip { font-size: 13px; gap: 8px; }
  .bf-konto-in { grid-template-columns: 1fr; gap: 28px; padding: 28px 20px; }
  .bf-lepki { left: 16px; right: 16px; transform: translateY(140%); justify-content: space-between; padding-left: 16px; }
  .bf-lepki.on { transform: none; }
  .bf-lepki span { font-size: 13px; white-space: normal; }
}
