:root {
  color-scheme: dark;
  --bg: #0b0710;
  --bg-soft: #14101a;
  --card: rgba(255,255,255,.075);
  --card-strong: rgba(255,255,255,.13);
  --text: #fff8ff;
  --muted: #b9aabc;
  --line: rgba(255,255,255,.18);
  --accent: #ff3ca6;
  --accent-2: #8b5cff;
  --gold: #ffd36a;
  --shadow: 0 26px 90px rgba(0,0,0,.45);
  --radius: 28px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'DM Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background:
    radial-gradient(circle at 12% 4%, rgba(255,60,166,.24), transparent 30rem),
    radial-gradient(circle at 82% 12%, rgba(139,92,255,.28), transparent 34rem),
    linear-gradient(180deg, #0b0710 0%, #120b18 46%, #09070d 100%);
  color: var(--text);
  min-height: 100vh;
}
body.modal-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.grain { position: fixed; inset: 0; pointer-events: none; opacity: .12; z-index: 0; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 250 250' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.7' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.45'/%3E%3C/svg%3E"); }
.site-header { position: sticky; top: 0; z-index: 20; display: flex; justify-content: space-between; align-items: center; padding: 18px clamp(18px, 4vw, 56px); backdrop-filter: blur(18px); background: rgba(8, 5, 12, .58); border-bottom: 1px solid rgba(255,255,255,.08); }
.brand, nav { display: flex; align-items: center; gap: 18px; color: var(--muted); font-weight: 800; letter-spacing: .08em; font-size: .78rem; }
.brand-mark { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: white; letter-spacing: 0; box-shadow: 0 0 26px rgba(255,60,166,.45); }
nav a { transition: color .2s; } nav a:hover { color: white; }
main, footer { position: relative; z-index: 1; }
.hero { min-height: 92vh; display: grid; place-items: center; text-align: center; padding: 92px 20px 56px; overflow: hidden; position: relative; }
.hero h1 { font-family: Manrope, sans-serif; font-size: clamp(5rem, 18vw, 15rem); line-height: .72; margin: 10px 0 24px; letter-spacing: -.09em; text-transform: uppercase; }
.hero h1 span { color: transparent; -webkit-text-stroke: 2px rgba(255,255,255,.85); text-shadow: 0 0 48px rgba(255,60,166,.36); }
.eyebrow { color: var(--gold); font-weight: 900; letter-spacing: .16em; font-size: .78rem; margin: 0 0 12px; }
.hero-copy { color: var(--muted); max-width: 620px; margin: 0 auto 28px; font-size: clamp(1rem, 2vw, 1.25rem); }
.hero-cta { display: inline-flex; align-items: center; gap: 10px; padding: 14px 20px; border-radius: 999px; background: white; color: #130815; font-weight: 900; box-shadow: 0 15px 45px rgba(255,255,255,.14); }
.hero-stats { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; margin-top: 42px; }
.hero-stats div { min-width: 150px; padding: 18px 22px; border: 1px solid var(--line); background: rgba(255,255,255,.07); border-radius: 22px; backdrop-filter: blur(12px); }
.hero-stats strong { display: block; font-size: 1.7rem; } .hero-stats span { color: var(--muted); }
.hero-glow, .hero-orbit { position: absolute; border-radius: 999px; pointer-events: none; }
.hero-glow { width: 55vmin; height: 55vmin; background: radial-gradient(circle, rgba(255,60,166,.35), transparent 65%); filter: blur(14px); }
.hero-orbit { border: 1px solid rgba(255,255,255,.14); transform: rotate(-18deg); }
.orbit-one { width: 78vmin; height: 32vmin; } .orbit-two { width: 96vmin; height: 46vmin; transform: rotate(24deg); }
.archive { padding: 90px clamp(16px, 4vw, 64px); }
.section-heading { display: flex; justify-content: space-between; gap: 28px; align-items: end; margin: 0 auto 28px; max-width: 1180px; }
.section-heading h2, .about h2 { font-family: Manrope, sans-serif; font-size: clamp(2.4rem, 6vw, 5.8rem); line-height: .9; letter-spacing: -.06em; margin: 0; }
.section-heading p:last-child { max-width: 450px; color: var(--muted); }
.controls { max-width: 1180px; margin: 0 auto; display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: center; }
.search-wrap, .sort-label, .filter-button { min-height: 54px; display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.075); color: var(--muted); padding: 0 16px; }
.search-wrap input { flex: 1; color: white; background: transparent; border: 0; outline: 0; min-width: 0; }
.search-wrap svg, .filter-button svg, .view-toggle svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; }
kbd { border: 1px solid var(--line); border-radius: 7px; padding: 2px 7px; color: var(--muted); }
.filter-button, .view-toggle, .load-more, .empty-state button, .gallery-actions button { border: 0; }
.filter-count { display: grid; place-items: center; min-width: 22px; height: 22px; border-radius: 999px; background: var(--accent); color: white; font-size: .76rem; }
.sort-label select { color: white; background: transparent; border: 0; outline: 0; }
.filter-panel { max-width: 1180px; margin: 12px auto 0; padding: 18px; border: 1px solid var(--line); border-radius: 22px; background: rgba(255,255,255,.075); }
.filter-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.filter-head button { background: transparent; border: 0; color: var(--gold); }
.type-filters { display: flex; flex-wrap: wrap; gap: 10px; }
.chip input { position: absolute; opacity: 0; }
.chip span { display: inline-flex; gap: 8px; align-items: center; padding: 10px 13px; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid transparent; color: var(--muted); }
.chip em { font-style: normal; opacity: .62; }
.chip input:checked + span { color: white; border-color: rgba(255,60,166,.7); background: rgba(255,60,166,.18); }
.year-scroller-wrap { max-width: 1180px; margin: 22px auto 0; display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; }
.year-scroller { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: thin; padding: 4px 2px 12px; }
.year-pill, .year-arrow { flex: 0 0 auto; color: var(--muted); background: rgba(255,255,255,.07); border: 1px solid var(--line); border-radius: 16px; padding: 10px 14px; }
.year-pill { display: grid; gap: 2px; min-width: 86px; text-align: left; } .year-pill span { font-size: .78rem; } .year-pill.active { color: white; border-color: rgba(255,60,166,.8); background: linear-gradient(135deg, rgba(255,60,166,.28), rgba(139,92,255,.18)); }
.results-row { max-width: 1180px; margin: 22px auto 14px; display: flex; align-items: center; justify-content: space-between; color: var(--muted); }
.view-toggle { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 15px; background: rgba(255,255,255,.08); color: white; }
.timeline { position: relative; max-width: 1180px; margin: 0 auto; padding: 38px 0 20px; }
.timeline::before { content: ''; position: absolute; top: 0; bottom: 0; left: 50%; width: 3px; transform: translateX(-50%); border-radius: 99px; background: linear-gradient(180deg, transparent, var(--accent), var(--accent-2), var(--gold), transparent); box-shadow: 0 0 36px rgba(255,60,166,.55); }
.event-card { position: relative; width: 50%; padding: 0 42px 38px; display: grid; grid-template-columns: 108px minmax(0, 1fr); gap: 16px; align-items: start; }
.event-card.left { margin-right: auto; text-align: right; grid-template-columns: minmax(0, 1fr) 108px; }
.event-card.right { margin-left: auto; }
.event-card.left .event-date { grid-column: 2; grid-row: 1; } .event-card.left .event-content { grid-column: 1; grid-row: 1; }
.event-dot { position: absolute; top: 28px; width: 25px; height: 25px; border-radius: 50%; background: var(--bg); border: 2px solid rgba(255,255,255,.35); display: grid; place-items: center; z-index: 2; }
.event-dot span { width: 11px; height: 11px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 22px var(--accent); }
.event-card.left .event-dot { right: -12.5px; } .event-card.right .event-dot { left: -12.5px; }
.event-date { color: var(--muted); padding-top: 14px; font-size: .78rem; }
.event-date strong { display: block; color: white; font-size: .92rem; } .event-date span { display: block; margin-top: 4px; }
.event-content { width: 100%; text-align: inherit; color: inherit; background: linear-gradient(145deg, rgba(255,255,255,.12), rgba(255,255,255,.045)); border: 1px solid rgba(255,255,255,.13); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); backdrop-filter: blur(18px); transition: transform .22s, border-color .22s, background .22s; }
.event-content:hover { transform: translateY(-6px); border-color: rgba(255,60,166,.55); background: linear-gradient(145deg, rgba(255,60,166,.18), rgba(255,255,255,.06)); }
.event-type { display: inline-flex; padding: 7px 10px; border-radius: 999px; color: var(--gold); background: rgba(255,211,106,.1); border: 1px solid rgba(255,211,106,.22); font-size: .74rem; font-weight: 900; letter-spacing: .04em; }
.event-content h3 { font-family: Manrope, sans-serif; font-size: clamp(1.1rem, 2vw, 1.55rem); line-height: 1.04; margin: 14px 0; letter-spacing: -.03em; }
.event-location { color: var(--muted); margin: -4px 0 12px; }
.thumb-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 14px 0; direction: ltr; }
.thumb { aspect-ratio: 1.1/1; border-radius: 16px; overflow: hidden; display: grid; place-items: center; background: linear-gradient(135deg, rgba(255,60,166,.28), rgba(139,92,255,.2)); border: 1px solid rgba(255,255,255,.12); color: rgba(255,255,255,.58); font-weight: 900; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; } .thumb.missing img { display: none; }
.event-meta { display: flex; justify-content: space-between; gap: 14px; align-items: center; color: var(--muted); font-size: .91rem; }
.open-detail { color: white; font-weight: 800; }
.load-more { display: flex; margin: 28px auto 0; padding: 15px 22px; border-radius: 999px; background: white; color: #150b18; font-weight: 900; }
.empty-state, .fatal-error { max-width: 640px; margin: 40px auto 0; text-align: center; padding: 34px; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(255,255,255,.075); color: var(--muted); }
.empty-state span { color: var(--accent); font-size: 2rem; } .empty-state h3 { color: white; margin-bottom: 4px; } .empty-state button { border-radius: 999px; padding: 12px 18px; background: var(--accent); color: white; font-weight: 900; }
.about { min-height: 70vh; display: grid; place-content: center; padding: 90px 20px; text-align: center; background: radial-gradient(circle at 50% 20%, rgba(255,60,166,.14), transparent 42rem); }
.about p:not(.eyebrow) { color: var(--muted); max-width: 620px; margin: 24px auto; font-size: 1.15rem; }
.about a { color: var(--gold); font-weight: 900; }
footer { display: flex; justify-content: space-between; gap: 20px; padding: 28px clamp(18px, 4vw, 56px); color: var(--muted); border-top: 1px solid rgba(255,255,255,.08); }
.event-dialog { width: min(1240px, calc(100vw - 28px)); max-height: min(900px, calc(100vh - 28px)); padding: 0; border: 1px solid rgba(255,255,255,.18); border-radius: 30px; color: white; background: rgba(13,9,18,.94); box-shadow: 0 30px 120px rgba(0,0,0,.72); overflow: hidden; }
.event-dialog::backdrop { background: rgba(0,0,0,.74); backdrop-filter: blur(12px); }
.dialog-close { position: absolute; top: 14px; right: 14px; z-index: 5; width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(255,255,255,.18); background: rgba(255,255,255,.12); color: white; font-size: 1.6rem; }
.gallery-overlay { display: grid; grid-template-columns: minmax(290px, 360px) 1fr; max-height: inherit; }
.gallery-info { padding: 34px; background: linear-gradient(180deg, rgba(255,60,166,.13), rgba(255,255,255,.04)); border-right: 1px solid rgba(255,255,255,.1); overflow: auto; }
.gallery-info h2 { font-family: Manrope, sans-serif; font-size: clamp(2rem, 4vw, 3.6rem); line-height: .95; letter-spacing: -.06em; margin: 18px 0; }
dl { display: grid; gap: 10px; margin: 20px 0; } dl div { display: flex; justify-content: space-between; gap: 18px; padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.1); } dt { color: var(--muted); } dd { margin: 0; text-align: right; font-weight: 800; }
.muted { color: var(--muted); } .legacy-link { display: inline-flex; margin-top: 18px; color: var(--gold); font-weight: 900; }
.gallery-stage { display: grid; grid-template-rows: minmax(300px, 1fr) auto minmax(180px, 280px); min-height: 76vh; }
.stage-photo { display: grid; place-items: center; background: radial-gradient(circle at 50% 20%, rgba(255,60,166,.15), transparent 40rem); min-height: 320px; }
.stage-photo img { width: 100%; height: 100%; max-height: 58vh; object-fit: contain; display: block; }
.stage-placeholder { width: min(560px, 82%); aspect-ratio: 16/10; border-radius: 30px; display: grid; place-items: center; text-align: center; background: linear-gradient(135deg, rgba(255,60,166,.26), rgba(139,92,255,.25)); border: 1px solid rgba(255,255,255,.16); }
.stage-placeholder strong { font-size: clamp(4rem, 14vw, 9rem); opacity: .36; } .stage-placeholder span { padding: 0 24px 24px; font-weight: 900; }
.gallery-actions { display: flex; align-items: center; justify-content: center; gap: 22px; padding: 14px; border-block: 1px solid rgba(255,255,255,.1); color: var(--muted); }
.gallery-actions button { width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,.1); color: white; }
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; padding: 14px; overflow: auto; }
.gallery-grid button, .gallery-placeholder { border: 1px solid rgba(255,255,255,.13); border-radius: 17px; overflow: hidden; background: rgba(255,255,255,.06); aspect-ratio: 1.25/1; }
.gallery-grid button.active { outline: 2px solid var(--accent); outline-offset: 2px; }
.gallery-grid img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-placeholder { display: grid; place-items: center; text-align: center; color: rgba(255,255,255,.58); padding: 10px; } .gallery-placeholder strong { font-size: 1.4rem; } .gallery-placeholder em { font-size: .7rem; font-style: normal; word-break: break-word; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skeleton { height: 180px; border-radius: var(--radius); background: linear-gradient(90deg, rgba(255,255,255,.06), rgba(255,255,255,.12), rgba(255,255,255,.06)); animation: pulse 1.2s infinite; }
@keyframes pulse { 50% { opacity: .55; } }
@media (max-width: 860px) {
  .site-header { position: static; } nav { display: none; }
  .section-heading, footer { display: block; }
  .controls { grid-template-columns: 1fr; }
  .timeline::before { left: 18px; }
  .event-card, .event-card.left, .event-card.right { width: 100%; margin: 0; padding: 0 0 28px 48px; text-align: left; grid-template-columns: 1fr; }
  .event-card.left .event-date, .event-card.left .event-content { grid-column: 1; grid-row: auto; }
  .event-dot, .event-card.left .event-dot, .event-card.right .event-dot { left: 6px; right: auto; }
  .event-date { padding-top: 0; }
  .gallery-overlay { grid-template-columns: 1fr; }
  .gallery-info { border-right: 0; border-bottom: 1px solid rgba(255,255,255,.1); padding: 24px; }
  .gallery-stage { min-height: 0; grid-template-rows: minmax(240px, 40vh) auto minmax(160px, 240px); }
  .stage-photo img { max-height: 40vh; }
}
@media (max-width: 560px) {
  .hero-stats div { min-width: 130px; }
  .event-content { padding: 14px; border-radius: 22px; }
  .thumb-strip { grid-template-columns: repeat(2, 1fr); }
  .event-meta { display: grid; }
  .year-arrow { display: none; }
  .year-scroller-wrap { grid-template-columns: 1fr; }
}


/* vertical-gallery-20260626: visible update marker and stronger timeline cards */
.version-badge {
  display: inline-grid;
  place-items: center;
  margin-left: 10px;
  padding: 4px 8px;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 999px;
  font-size: .62rem;
  font-style: normal;
  letter-spacing: .08em;
  color: var(--gold);
  background: rgba(255,255,255,.07);
}
.timeline { position: relative; padding: 28px 0 10px; }
.timeline::after {
  content: 'PIONOWA OŚ · GALERIE';
  position: sticky;
  top: 76px;
  left: calc(50% - 58px);
  z-index: 3;
  display: inline-block;
  margin-left: calc(50% - 70px);
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(12,8,18,.78);
  border: 1px solid rgba(255,255,255,.14);
  color: rgba(255,255,255,.72);
  font-size: .66rem;
  letter-spacing: .12em;
  backdrop-filter: blur(14px);
}
.event-content {
  width: 100%;
  min-height: 230px;
  cursor: zoom-in;
  transform: translateZ(0);
}
.event-content:hover { transform: translateY(-4px); box-shadow: 0 22px 70px rgba(255,60,166,.20); }
.thumb-strip {
  display: grid;
  grid-template-columns: 1.25fr .85fr .85fr .85fr;
  gap: 8px;
  margin: 16px 0 14px;
  min-height: 92px;
}
.thumb {
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 16px;
  background: radial-gradient(circle at 30% 20%, rgba(255,60,166,.45), rgba(123,92,255,.12) 55%, rgba(255,255,255,.05));
  border: 1px solid rgba(255,255,255,.13);
  color: rgba(255,255,255,.76);
  font-weight: 800;
  min-height: 88px;
}
.thumb:first-child { grid-row: span 2; min-height: 188px; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb.placeholder::before { content: 'miniatura'; position: absolute; font-size: .58rem; margin-top: 38px; opacity: .65; text-transform: uppercase; letter-spacing: .12em; }
.thumb.missing img { display: none; }
.thumb.missing::after { content: 'brak pliku'; font-size: .7rem; opacity: .7; }
.gallery-overlay { min-height: min(84vh, 900px); }
.event-dialog::backdrop { background: rgba(4,3,8,.78); backdrop-filter: blur(8px); }
@media (max-width: 760px) {
  .version-badge { display: none; }
  .timeline::after { margin-left: 36px; left: 0; top: 68px; }
  .event-content { min-height: 0; }
  .thumb-strip { grid-template-columns: repeat(4, 1fr); min-height: 72px; }
  .thumb, .thumb:first-child { grid-row: auto; min-height: 72px; }
}


/* vertical-gallery-v4: czytelne miniatury bez nakładania */
.thumb-strip {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  grid-template-rows: 92px 92px !important;
  gap: 8px !important;
  min-height: 0 !important;
  height: 192px !important;
  overflow: hidden !important;
  direction: ltr !important;
}
.thumb {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  aspect-ratio: auto !important;
  border-radius: 14px !important;
  overflow: hidden !important;
  line-height: 0 !important;
}
.thumb:first-child {
  grid-column: 1 / span 2 !important;
  grid-row: 1 / span 2 !important;
  min-height: 0 !important;
}
.thumb:nth-child(2) { grid-column: 3; grid-row: 1; }
.thumb:nth-child(3) { grid-column: 4; grid-row: 1; }
.thumb:nth-child(4) { grid-column: 3 / span 2; grid-row: 2; }
.thumb img {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  display: block !important;
  vertical-align: top !important;
}
.gallery-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)) !important;
  grid-auto-rows: 92px !important;
  align-items: stretch !important;
  gap: 12px !important;
  padding: 16px !important;
  overflow: auto !important;
  min-height: 0 !important;
}
.gallery-grid button,
.gallery-placeholder {
  appearance: none !important;
  -webkit-appearance: none !important;
  display: block !important;
  width: 100% !important;
  height: 92px !important;
  min-width: 0 !important;
  min-height: 0 !important;
  max-width: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
  border-radius: 14px !important;
  overflow: hidden !important;
  line-height: 0 !important;
  aspect-ratio: auto !important;
  cursor: pointer !important;
}
.gallery-grid img {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  display: block !important;
  vertical-align: top !important;
}
.gallery-grid button.active {
  outline: 3px solid var(--accent) !important;
  outline-offset: 2px !important;
}
.stage-photo {
  overflow: hidden !important;
}
.stage-photo img {
  width: 100% !important;
  height: 100% !important;
  max-height: 58vh !important;
  object-fit: contain !important;
}
@media (max-width: 760px) {
  .thumb-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-template-rows: 130px 74px !important;
    height: 212px !important;
  }
  .thumb:first-child { grid-column: 1 / span 2 !important; grid-row: 1 !important; }
  .thumb:nth-child(2) { grid-column: 1; grid-row: 2; }
  .thumb:nth-child(3) { grid-column: 2; grid-row: 2; }
  .thumb:nth-child(4) { display: none !important; }
  .gallery-grid { grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)) !important; grid-auto-rows: 74px !important; }
  .gallery-grid button, .gallery-placeholder { height: 74px !important; }
}
