/* bancerz.pl */
:root {
  --ground: #F2F4F7;
  --paper: #FFFFFF;
  --ink: #111C3A;
  --muted: #4A5573;
  --line: #D5DAE5;
  --accent: #2343D3;
  --accent-dark: #16298C;
  --mark: #F2B632;
  --on-dark: #E8ECF6;
  --on-dark-muted: #C9D2E8;
  --sky: #8FB0FF;
  --display: 'Bricolage Grotesque', system-ui, sans-serif;
  --text: 'Source Serif 4', Georgia, serif;
  --gutter: clamp(20px, 5vw, 64px);
  --band: clamp(48px, 7vw, 96px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font-family: var(--text); font-size: 18px; line-height: 1.6; }
img, video { max-width: 100%; display: block; }
[hidden] { display: none !important; }

a { color: var(--accent); }
a:hover { color: var(--accent-dark); }
.dark a { color: var(--mark); }
.dark a:hover { color: #FFD778; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.dark :focus-visible { outline-color: var(--mark); }

h1, h2, h3 { font-family: var(--display); margin: 0; }
h2 { font-size: clamp(30px, 3.6vw, 44px); line-height: 1.1; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 20px; }
h3 { font-size: 22px; font-weight: 600; }
p { margin: 0 0 20px; max-width: 62ch; }

.wrap { max-width: 1280px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.band { padding: var(--band) 0; }
.band--white { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dark { background: var(--ink); color: var(--on-dark); }
.dark h2, .dark h3 { color: #FFFFFF; }
.meta { font-size: 16px; color: var(--muted); }
.dark .meta { color: var(--on-dark-muted); }
.intro { margin-bottom: 36px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 10; background: #FFFFFF; padding: 12px 16px; }

/* Nagłówek */
.header { border-bottom: 1px solid var(--line); }
.header__in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding-top: 16px; padding-bottom: 16px; }
.brand { font-family: var(--display); font-size: 21px; font-weight: 700; color: var(--ink); text-decoration: none; padding: 10px 0; }
.nav { display: flex; flex-wrap: wrap; gap: 0 32px; font-family: var(--display); font-size: 16px; font-weight: 500; }
.nav a { color: var(--ink); text-decoration: none; padding: 12px 0; }
.nav a:hover { text-decoration: underline; }
.menu-btn { display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 16px; background: transparent; border: 1.5px solid var(--ink); border-radius: 6px; font-family: var(--display); font-size: 16px; font-weight: 600; color: var(--ink); cursor: pointer; }

/* Przyciski */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 24px; border-radius: 6px; font-family: var(--display); font-size: 17px; font-weight: 600; text-decoration: none; }
.dark .btn--primary { background: var(--mark); color: var(--ink); }
.dark .btn--primary:hover { background: #FFD778; color: var(--ink); }
.dark .btn--ghost { border: 1.5px solid #FFFFFF; color: #FFFFFF; }
.dark .btn--ghost:hover { background: rgba(255, 255, 255, 0.12); color: #FFFFFF; }
.btn-small { min-height: 44px; padding: 0 16px; background: transparent; border: 1.5px solid currentColor; border-radius: 6px; font-family: var(--display); font-size: 15px; font-weight: 600; color: inherit; cursor: pointer; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; max-width: none; }

/* Hero */
.hero { position: relative; overflow: hidden; color: #FFFFFF; }
.hero__bg { position: absolute; inset: 0; }
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(14px); transform: scale(1.08); }
.hero__veil { position: absolute; inset: 0; background: rgba(17, 28, 58, 0.55); }
.blob { position: absolute; aspect-ratio: 1 / 1; border-radius: 50%; filter: blur(70px); }
.blob--1 { left: -10%; top: -30%; width: 60%; background: var(--accent); animation: drift1 14s ease-in-out infinite; }
.blob--2 { right: -8%; bottom: -45%; width: 50%; background: var(--mark); opacity: 0.55; animation: drift2 18s ease-in-out infinite; }
.blob--3 { left: 40%; top: 5%; width: 32%; background: var(--sky); opacity: 0.45; animation: drift2 22s ease-in-out infinite; }
.hero.is-paused .blob { animation-play-state: paused; }
@keyframes drift1 { 0%, 100% { transform: translate(0, 0) scale(1); } 50% { transform: translate(14%, 10%) scale(1.18); } }
@keyframes drift2 { 0%, 100% { transform: translate(0, 0) scale(1.1); } 50% { transform: translate(-12%, -8%) scale(0.92); } }

.hero__in { position: relative; min-height: clamp(560px, 52vw, 760px); padding-top: clamp(40px, 6vw, 88px); padding-bottom: 28px; display: flex; flex-direction: column; justify-content: space-between; gap: 40px; }
.hero__text { display: flex; flex-direction: column; gap: 24px; }
.hero h1 { font-size: clamp(54px, 8.5vw, 120px); line-height: 0.95; font-weight: 700; letter-spacing: -0.04em; }
.hero__lead { margin: 0; max-width: 34ch; font-family: var(--display); font-size: clamp(20px, 2.2vw, 28px); line-height: 1.3; font-weight: 500; }
.hero__bottom { display: flex; flex-direction: column; gap: 20px; }
.hero__control { margin: 0; max-width: none; display: flex; justify-content: flex-end; color: #FFFFFF; }

.media-rail { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 16px; }
.media-card { display: flex; align-items: center; gap: 16px; padding: 16px; background: rgba(17, 28, 58, 0.6); border: 1px solid rgba(255, 255, 255, 0.24); border-radius: 10px; -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); font-family: var(--display); font-size: 17px; line-height: 1.3; color: #FFFFFF; text-align: left; }
.media-card strong { display: block; font-weight: 600; }
.media-card small { display: block; font-size: 15px; color: var(--on-dark-muted); }
.media-card--link { text-decoration: none; cursor: pointer; }
.dark a.media-card--link, .dark a.media-card--link:hover { color: #FFFFFF; }
.media-card--link:hover { background: rgba(17, 28, 58, 0.8); }
.media-card--audio { flex-direction: column; align-items: stretch; gap: 10px; }
.media-card audio { width: 100%; height: 40px; }
.play { flex: 0 0 52px; height: 52px; border-radius: 50%; background: var(--mark); color: var(--ink); display: flex; align-items: center; justify-content: center; }
.thumbs { flex: 0 0 auto; display: flex; gap: 4px; }
.thumbs i { width: 30px; height: 52px; border-radius: 4px; background: #7F90C2; }
.thumbs i:first-child { background: #5C6FA8; }
.thumbs i:last-child { background: #A9B4D0; }

/* Biogram */
.bio { display: flex; flex-wrap: wrap; gap: clamp(28px, 5vw, 72px); }
.bio__photo { flex: 0 1 380px; min-width: 240px; width: 380px; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 6px; align-self: flex-start; }
.bio__text { flex: 999 1 420px; min-width: 0; }

.player { margin: 32px 0 0; max-width: 640px; }
.player video { width: 100%; aspect-ratio: 16 / 9; background: var(--ink); border-radius: 6px; }
.player figcaption { margin-top: 12px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font-family: var(--display); font-size: 16px; color: var(--muted); }
.player figcaption a { padding: 10px 0; margin: -10px 0; }

/* Badania */
.research { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(32px, 5vw, 72px); }
.research__text { flex: 999 1 460px; min-width: 0; }
.thesis { font-family: var(--display); font-size: clamp(21px, 2.2vw, 26px); line-height: 1.3; font-weight: 500; color: #FFFFFF; max-width: 30ch; margin-bottom: 8px; }
.cols { display: flex; flex-wrap: wrap; gap: 24px 48px; margin-top: 28px; }
.cols > div { flex: 1 1 240px; }
.cols h3 { font-size: 18px; margin-bottom: 8px; }
.cols ul { margin: 0; padding-left: 20px; font-size: 17px; }

.arenas { flex: 1 1 380px; min-width: 0; max-width: 520px; margin: 0; }
.arenas__stage { position: relative; width: 100%; aspect-ratio: 13 / 10; }
.edge { position: absolute; height: 2px; width: 60%; background: #3B4A75; transform-origin: 0 50%; }
.edge--ab { left: 50%; top: 17.5%; transform: rotate(120deg); }
.edge--ac { left: 50%; top: 17.5%; transform: rotate(60deg); }
.edge--bc { left: 20%; top: 85%; }
.node { position: absolute; transform: translate(-50%, -50%); white-space: nowrap; background: var(--ink); border: 2px solid var(--sky); border-radius: 999px; padding: 10px 16px; font-family: var(--display); font-size: 15px; font-weight: 600; color: #FFFFFF; }
.node--a { left: 50%; top: 17.5%; }
.node--b { left: 20%; top: 85%; }
.node--c { left: 80%; top: 85%; }
.dot { position: absolute; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: var(--mark); }
.dot--1 { animation: ab 4s linear infinite; }
.dot--2 { animation: ab 4s linear -2s infinite reverse; background: var(--sky); }
.dot--3 { animation: bc 4s linear -1s infinite; }
.dot--4 { animation: bc 4s linear -3s infinite reverse; background: var(--sky); }
.dot--5 { animation: ca 4s linear -2.5s infinite; }
.dot--6 { animation: ca 4s linear -0.5s infinite reverse; background: var(--sky); }
.arenas.is-paused .dot { animation-play-state: paused; }
@keyframes ab { from { left: 50%; top: 17.5%; } to { left: 20%; top: 85%; } }
@keyframes bc { from { left: 20%; top: 85%; } to { left: 80%; top: 85%; } }
@keyframes ca { from { left: 80%; top: 85%; } to { left: 50%; top: 17.5%; } }
.arenas figcaption { margin-top: 20px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; font-family: var(--display); font-size: 16px; color: var(--on-dark-muted); }
.arenas .btn-small { color: #FFFFFF; }

/* Listy: publikacje i projekty */
.rows { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid var(--line); }
.row { display: grid; grid-template-columns: 140px minmax(0, 1fr) 220px 170px; column-gap: 24px; align-items: baseline; padding: 22px 0; border-top: 1px solid var(--line); }
.row__type, .row__link { font-family: var(--display); font-size: 16px; }
.row__type { color: var(--muted); }
.row__title { font-family: var(--display); font-size: 20px; font-weight: 600; line-height: 1.3; }
.row__meta { font-size: 16px; color: var(--muted); }
.row__link a { font-weight: 600; display: inline-block; padding: 10px 0; margin: -10px 0; }

.projects__video { margin: 0 0 48px; max-width: 760px; }
.projects { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(440px, 100%), 1fr)); gap: 56px clamp(28px, 4vw, 56px); }
.project { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.project__shot { display: block; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--ground); }
.project__shot img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top center; }
.project h3 { font-size: 24px; margin-top: 8px; overflow-wrap: anywhere; }
.project h3 a { display: inline-block; padding: 6px 0; }
.project p { margin: 0; font-size: 17px; }

/* Stopka i kontakt */
.footer { padding-bottom: 32px; }
.email { display: inline-block; padding: 8px 0; font-family: var(--display); font-size: clamp(24px, 3.4vw, 40px); font-weight: 600; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.links { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 36px; font-family: var(--display); font-size: 17px; font-weight: 500; }
.links a { display: inline-block; padding: 12px 0; }
.footer__end { margin: 56px 0 0; padding-top: 20px; max-width: none; border-top: 1px solid #3B4A75; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font-family: var(--display); font-size: 15px; color: var(--on-dark-muted); }
.footer__end a { padding: 10px 0; margin: -10px 0; }

/* Galeria */
.dialog { width: min(1100px, calc(100% - 32px)); max-height: calc(100% - 32px); padding: 24px; border: 0; border-radius: 10px; background: var(--paper); color: var(--ink); }
.dialog::backdrop { background: rgba(17, 28, 58, 0.8); }
.dialog__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.dialog__head h2 { margin: 0; font-size: 28px; }
.dialog__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr)); gap: 12px; }
.dialog__grid img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; }

/* Wąskie ekrany */
@media (max-width: 760px) {
  .js .nav { display: none; flex-direction: column; flex-basis: 100%; font-size: 18px; }
  .js .nav.is-open { display: flex; }
  .js .nav a { border-top: 1px solid var(--line); }
  .actions .btn { flex: 1 1 100%; }
  .hero__control { justify-content: flex-start; }
  .bio__photo { width: 100%; flex-basis: 100%; }
  .row { grid-template-columns: minmax(0, 1fr); row-gap: 4px; }
  .row__meta:empty, .row__link:empty { display: none; }
  .node { font-size: 14px; padding: 8px 12px; }
  .dot { width: 10px; height: 10px; margin: -5px 0 0 -5px; }
}
@media (min-width: 761px) {
  .menu-btn { display: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .blob, .dot { animation: none !important; }
}

@media print {
  .hero__bg, .menu-btn, .btn-small, video, audio, .arenas { display: none !important; }
  .hero, .dark { background: #FFFFFF; color: #000000; }
  .dark h2, .dark h3, .hero h1, .thesis { color: #000000; }
}
