/* ============================================================
   dudka.pro — global styles
   ============================================================ */
:root {
  --bg: #0b1020;
  --bg-soft: #121a33;
  --surface: #ffffff;
  --surface-soft: #f5f7fb;
  --text: #0d1426;
  --text-soft: #4a5670;
  --text-invert: #eaf0ff;
  --muted: #8b97b5;
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --accent: #10b981;
  --accent-dark: #059669;
  --gold: #f59e0b;
  --border: #e4e9f2;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px rgba(13, 20, 38, 0.08);
  --shadow-lg: 0 24px 60px rgba(13, 20, 38, 0.18);
  --maxw: 1140px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: 88px 0; }
.section--soft { background: var(--surface-soft); }
.section--dark { background: var(--bg); color: var(--text-invert); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: 13px;
  font-weight: 700;
  color: var(--brand);
  margin: 0 0 12px;
}
.section--dark .eyebrow { color: var(--accent); }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.02em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.6rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1rem; }
.lead { font-size: 1.18rem; color: var(--text-soft); }
.section--dark .lead { color: #b9c4e6; }
.center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.maxw-text { max-width: 720px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 26px; border-radius: 999px; font-weight: 700; font-size: 1rem;
  cursor: pointer; border: 2px solid transparent; transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { background: var(--brand-dark); box-shadow: 0 12px 24px rgba(37,99,235,.35); }
.btn--accent { background: var(--accent); color: #042f24; }
.btn--accent:hover { background: var(--accent-dark); color: #fff; box-shadow: 0 12px 24px rgba(16,185,129,.35); }
.btn--ghost { background: transparent; border-color: var(--border); color: var(--text); }
.section--dark .btn--ghost,
.hero .btn--ghost,
.page-hero .btn--ghost { border-color: rgba(255,255,255,.3); color: #fff; }
.btn--ghost:hover { border-color: var(--brand); color: var(--brand); }
.section--dark .btn--ghost:hover,
.hero .btn--ghost:hover,
.page-hero .btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--lg { padding: 17px 34px; font-size: 1.08rem; }
.btn--block { width: 100%; }

/* ---------- header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.85); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.2rem; letter-spacing: -.02em; }
.brand .dot { color: var(--brand); }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--brand), var(--accent)); color: #fff; font-weight: 900;
}
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { font-weight: 600; color: var(--text-soft); font-size: .98rem; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: 12px; }

.lang-toggle {
  display: inline-flex; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; background: #fff;
}
.lang-toggle button {
  border: 0; background: transparent; padding: 7px 12px; font-weight: 700; font-size: .85rem; cursor: pointer; color: var(--muted);
}
.lang-toggle button.active { background: var(--brand); color: #fff; }

/* Lista jezykow (8 pozycji) — zastapila dwuprzyciskowy przelacznik PL/EN.
   Opcje wstrzykuje js/i18n.js z tablicy LANGS, wiec HTML zostaje pusty. */
.lang-select {
  border: 1px solid var(--border); border-radius: 999px; background: #fff;
  padding: 7px 10px; font-weight: 700; font-size: .85rem; color: var(--muted);
  cursor: pointer; max-width: 9.5rem;
}
.lang-select:hover { color: var(--text); }
.lang-select:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

/* CJK: fonty tych stron nie maja glifow koreanskich/japonskich/chinskich —
   sciagamy je z systemu (ten sam zabieg co w SPA: web/src/index.css). */
html:lang(ko) body, html:lang(ko) .lang-select {
  font-family: "Apple SD Gothic Neo", Pretendard, "Noto Sans KR", "Malgun Gothic", system-ui, sans-serif;
}
html:lang(ja) body, html:lang(ja) .lang-select {
  font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", Meiryo, system-ui, sans-serif;
}
html:lang(zh) body, html:lang(zh) .lang-select {
  font-family: "PingFang SC", "Noto Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", system-ui, sans-serif;
}
html:lang(ko), html:lang(ja), html:lang(zh) { line-break: strict; }
html:lang(ko) body { word-break: keep-all; overflow-wrap: break-word; }

.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--text); margin: 5px 0; transition: .2s; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(1200px 600px at 80% -10%, #1e2a52 0, transparent 60%),
              radial-gradient(900px 500px at 0% 10%, #14233f 0, transparent 55%),
              var(--bg);
  color: var(--text-invert); padding: 92px 0 96px;
}
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }
.hero h1 { color: #fff; }
.hero .lead { color: #c7d2f0; max-width: 540px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }
.hero-badges { display: flex; gap: 22px; margin-top: 34px; flex-wrap: wrap; }
.hero-badge { font-size: .9rem; color: #aeb9dd; display: flex; align-items: center; gap: 8px; }
.hero-badge b { color: #fff; }
.hero-card {
  background: linear-gradient(160deg, rgba(255,255,255,.08), rgba(255,255,255,.02));
  border: 1px solid rgba(255,255,255,.12); border-radius: 22px; padding: 28px; backdrop-filter: blur(6px);
}
.chat-demo { display: flex; flex-direction: column; gap: 12px; }
.chat-bubble { padding: 12px 16px; border-radius: 14px; font-size: .95rem; max-width: 85%; }
.chat-bubble--bot { background: rgba(16,185,129,.16); border: 1px solid rgba(16,185,129,.3); align-self: flex-start; }
.chat-bubble--me { background: rgba(37,99,235,.22); border: 1px solid rgba(37,99,235,.4); align-self: flex-end; }
.chat-meta { font-size: .78rem; color: #9fb0da; }

/* ---------- product cards ---------- */
.grid { display: grid; gap: 26px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 30px; box-shadow: var(--shadow); transition: transform .2s ease, box-shadow .2s ease;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card .icon {
  width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; font-size: 1.5rem; margin-bottom: 18px;
}
.icon--blue { background: #e7efff; }
.icon--green { background: #e3f8f0; }
.icon--gold { background: #fff2d9; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--text-soft); }
.card .btn { margin-top: auto; align-self: flex-start; }
.tag {
  display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
  padding: 5px 10px; border-radius: 999px; margin-bottom: 16px;
}
.tag--blue { background: #e7efff; color: var(--brand-dark); }
.tag--green { background: #e3f8f0; color: var(--accent-dark); }
.tag--gold { background: #fff2d9; color: #b45309; }

/* ---------- features ---------- */
.feature { display: flex; gap: 16px; align-items: flex-start; }
.feature .fi { font-size: 1.4rem; flex: 0 0 auto; }
.feature h3 { font-size: 1.08rem; margin-bottom: 4px; }
.feature p { color: var(--text-soft); margin: 0; font-size: .96rem; }
.section--dark .feature p { color: #b9c4e6; }

/* ---------- pricing ---------- */
.pricing { display: grid; grid-template-columns: repeat(3,1fr); gap: 26px; align-items: stretch; }
.price-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 32px; position: relative;
  display: flex; flex-direction: column; box-shadow: var(--shadow);
}
.price-card.popular { border-color: var(--brand); box-shadow: 0 20px 50px rgba(37,99,235,.22); transform: scale(1.03); }
.price-card .badge {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--brand); color: #fff; font-size: .74rem; font-weight: 800; padding: 5px 14px; border-radius: 999px;
  letter-spacing: .06em; text-transform: uppercase;
}
.price-card h3 { margin-bottom: 4px; }
.price { font-size: 2.6rem; font-weight: 900; letter-spacing: -.03em; margin: 8px 0 2px; }
.price small { font-size: 1rem; font-weight: 600; color: var(--muted); }
.price-sub { color: var(--text-soft); font-size: .92rem; margin-bottom: 18px; }
.price-list { list-style: none; padding: 0; margin: 0 0 26px; display: flex; flex-direction: column; gap: 10px; }
.price-list li { display: flex; gap: 10px; align-items: flex-start; color: var(--text-soft); font-size: .96rem; }
.price-list li::before { content: "✓"; color: var(--accent-dark); font-weight: 900; }
.price-list li.off { color: var(--muted); }
.price-list li.off::before { content: "—"; color: var(--muted); }

/* ---------- steps ---------- */
.steps { counter-reset: step; display: grid; gap: 22px; grid-template-columns: repeat(3,1fr); }
.step { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; position: relative; }
.step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--brand); color: #fff; font-weight: 900; margin-bottom: 14px;
}

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(135deg, var(--brand), var(--accent)); color: #fff; border-radius: 26px; padding: 56px;
  text-align: center; box-shadow: var(--shadow-lg);
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.9); }

/* ---------- FAQ ---------- */
.faq-item { border-bottom: 1px solid var(--border); }
.faq-q { width: 100%; text-align: left; background: none; border: 0; padding: 22px 0; font-size: 1.08rem; font-weight: 700;
  cursor: pointer; display: flex; justify-content: space-between; gap: 16px; color: var(--text); }
.faq-q::after { content: "+"; color: var(--brand); font-weight: 900; transition: transform .2s; }
.faq-item.open .faq-q::after { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .25s ease; color: var(--text-soft); }
.faq-item.open .faq-a { max-height: 320px; padding-bottom: 22px; }

/* ---------- forms ---------- */
.form-row { display: flex; gap: 12px; flex-wrap: wrap; }
.input {
  flex: 1; min-width: 220px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 1rem; font-family: inherit; background: #fff;
}
.input:focus { outline: 2px solid var(--brand); border-color: var(--brand); }

/* ---------- footer ---------- */
.site-footer { background: var(--bg); color: #aeb9dd; padding: 56px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
.site-footer h4 { color: #fff; font-size: .95rem; margin: 0 0 14px; letter-spacing: .04em; text-transform: uppercase; }
.site-footer a { display: block; color: #aeb9dd; padding: 5px 0; font-size: .95rem; }
.site-footer a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 40px; padding-top: 22px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: .88rem; color: var(--muted); }

/* ---------- page hero (subpages) ---------- */
.page-hero { background: var(--bg); color: var(--text-invert); padding: 72px 0; }
.page-hero h1 { color: #fff; }
.page-hero .lead { color: #c7d2f0; max-width: 680px; }

/* ---------- misc ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.notice {
  background: #fff7e6; border: 1px solid #ffe2a8; color: #92600a; border-radius: var(--radius-sm);
  padding: 14px 18px; font-size: .92rem; margin-top: 18px;
}
.kicker-list { list-style: none; padding: 0; margin: 18px 0; display: flex; flex-direction: column; gap: 12px; }
.kicker-list li { display: flex; gap: 12px; align-items: flex-start; }
.kicker-list li::before { content: "✓"; color: var(--accent-dark); font-weight: 900; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero-grid, .split { grid-template-columns: 1fr; }
  .grid-3, .grid-2, .pricing, .steps, .footer-grid { grid-template-columns: 1fr; }
  .price-card.popular { transform: none; }
  .nav-links { position: fixed; inset: 68px 0 auto 0; background: #fff; flex-direction: column; gap: 0;
    border-bottom: 1px solid var(--border); padding: 12px 24px; display: none; }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 0; width: 100%; border-bottom: 1px solid var(--surface-soft); }
  .nav-toggle { display: block; }
  .cta-band { padding: 36px 22px; }
  .footer-bottom { flex-direction: column; }
}

/* ---------- chat (Trener AI) ---------- */
.chat-page { background: var(--surface-soft); min-height: 100vh; display: flex; flex-direction: column; }
.chat-shell { flex: 1; display: flex; flex-direction: column; max-width: 820px; width: 100%;
  margin: 0 auto; padding: 16px; }
.chat-head { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  margin-bottom: 12px; }
.chat-head h2 { margin: 0; font-size: 1.05rem; }
.chat-head .chat-sub { margin: 2px 0 0; font-size: .82rem; color: var(--muted); }
.chat-log { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 12px;
  padding: 18px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); }
.msg { max-width: 80%; padding: 12px 15px; border-radius: 16px; line-height: 1.5; white-space: pre-wrap;
  font-size: .95rem; }
.msg--bot { align-self: flex-start; background: var(--surface-soft); color: var(--text);
  border-bottom-left-radius: 4px; }
.msg--me { align-self: flex-end; background: var(--brand); color: #fff; border-bottom-right-radius: 4px; }
.msg--typing { color: var(--muted); font-style: italic; }
.chat-form { display: flex; gap: 10px; margin-top: 12px; }
.chat-form textarea { flex: 1; resize: none; font: inherit; padding: 12px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); max-height: 140px; }
.chat-form textarea:focus { outline: none; border-color: var(--brand); }
.chat-gate { max-width: 520px; margin: 64px auto; text-align: center; background: #fff;
  border: 1px solid var(--border); border-radius: var(--radius); padding: 40px 32px; }
.chat-gate h2 { margin-top: 0; }

/* ---------- about: timeline ---------- */
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { display: flex; gap: 18px; align-items: baseline; padding: 14px 0;
  border-bottom: 1px solid var(--border); }
.timeline li:last-child { border-bottom: 0; }
.timeline .tl-when { flex: 0 0 110px; font-weight: 800; color: var(--brand); font-variant-numeric: tabular-nums; }
.timeline .tl-what { font-weight: 600; }
.timeline .tl-what em { font-style: normal; color: var(--muted); font-weight: 500; }

/* ---------- about: photo ---------- */
.about-photo { margin: 0; text-align: center; }
.about-photo img {
  width: 100%; max-width: 340px; height: auto; display: block; margin: 0 auto;
  border-radius: var(--radius); background: rgba(255,255,255,.04);
  filter: drop-shadow(0 18px 40px rgba(0,0,0,.35));
}
.about-photo figcaption { margin-top: 14px; color: #c7d2f0; font-size: .92rem; font-weight: 600; }

/* photo variant on light background */
.about-photo--light img { filter: drop-shadow(0 14px 32px rgba(15,23,42,.18)); }

/* ---------- legal pages (regulamin, polityka) ---------- */
.legal { max-width: 820px; }
.legal h1 { margin-bottom: 8px; }
.legal .legal-meta { color: var(--muted); font-size: .9rem; margin: 0 0 32px; }
.legal h2 { font-size: 1.25rem; margin: 32px 0 10px; }
.legal p, .legal li { color: var(--text-soft); line-height: 1.7; }
.legal ul, .legal ol { padding-left: 22px; margin: 8px 0; }
.legal li { margin: 6px 0; }
.legal .placeholder { background: #fff7e6; border: 1px solid #ffe2a8; color: #92600a;
  padding: 2px 6px; border-radius: 6px; font-size: .9em; }

/* ---------- player base (zawodnicy) ---------- */
.pform { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pform .full { grid-column: 1 / -1; }
.pform label { display: block; font-size: .82rem; font-weight: 700; margin-bottom: 4px; color: var(--text-soft); }
.pform input, .pform textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); font: inherit; box-sizing: border-box; }
.pform input:focus, .pform textarea:focus { outline: none; border-color: var(--brand); }
.pform textarea { resize: vertical; min-height: 60px; }
.players-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; margin-top: 24px; }
.pcard .meta { color: var(--muted); font-size: .9rem; margin: 2px 0 12px; }
.pcard .row { font-size: .92rem; margin: 5px 0; color: var(--text-soft); }
.pcard .row b { color: var(--text); font-weight: 700; }
.pcard-actions { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
@media (max-width: 640px) { .pform { grid-template-columns: 1fr; } }

/* ---------- Indeks Środowiska (ankieta) ---------- */
.quiz-q { padding: 16px 0; border-bottom: 1px solid var(--border); }
.quiz-q:first-child { padding-top: 0; }
.quiz-text { font-weight: 700; margin: 0 0 12px; }
.quiz-opts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.quiz-opt { display: flex; align-items: center; gap: 6px; padding: 8px 10px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); cursor: pointer; font-size: .82rem; transition: border-color .15s, background .15s; }
.quiz-opt:hover { border-color: var(--brand); }
.quiz-opt input { accent-color: var(--brand); }
.quiz-opt:has(input:checked) { border-color: var(--brand); background: #eef4ff; font-weight: 700; }
.score-big { font-size: 4.5rem; font-weight: 900; line-height: 1; }
.score-big small { font-size: 1.4rem; color: var(--muted); font-weight: 700; }
.dims { margin: 24px 0 0; display: flex; flex-direction: column; gap: 10px; text-align: left; }
.dim-row { display: grid; grid-template-columns: 150px 1fr 44px; align-items: center; gap: 12px; font-size: .9rem; }
.dim-bar { background: var(--surface-soft); border-radius: 999px; height: 10px; overflow: hidden; }
.dim-bar i { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.dim-row b { text-align: right; font-variant-numeric: tabular-nums; }
.tips { text-align: left; list-style: none; padding: 0; margin: 12px 0 0; display: flex; flex-direction: column; gap: 14px; }
.tips li { padding-left: 26px; position: relative; line-height: 1.6; color: var(--text-soft); }
.tips li::before { content: "→"; position: absolute; left: 0; color: var(--accent-dark); font-weight: 900; }
@media (max-width: 560px) { .quiz-opts { grid-template-columns: 1fr 1fr; } .dim-row { grid-template-columns: 110px 1fr 40px; } }

/* ---------- modal (plan rozwoju) ---------- */
.modal { position: fixed; inset: 0; background: rgba(13,20,38,.55); display: flex;
  align-items: center; justify-content: center; padding: 20px; z-index: 1000; }
.modal-box { background: #fff; border-radius: var(--radius); padding: 26px; width: 100%;
  max-width: 640px; max-height: 88vh; overflow: auto; box-shadow: var(--shadow-lg); }
.modal-box h3 { margin: 0 0 14px; }
.modal-box textarea { width: 100%; box-sizing: border-box; font: inherit; line-height: 1.6;
  padding: 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); resize: vertical;
  white-space: pre-wrap; }
.modal-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }

/* ---------- player badges (env score / plan) ---------- */
.pbadges { display: flex; flex-wrap: wrap; gap: 8px; margin: 2px 0 12px; }
.pbadge { font-size: .78rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.pbadge--env { background: #eef4ff; color: var(--brand-dark); }
.pbadge--plan { background: #e3f8f0; color: var(--accent-dark); }

/* ---------- print (paszport PDF) ---------- */
@media print { .no-print { display: none !important; } body { background: #fff; } .section { padding: 0; } }
