/*
  wspolne.css — style WYŁĄCZNIE nagłówka (pt-header) i stopki (pt-footer).
  Prefiks klas: pt-. Wszystkie wartości jawne, żeby przetrwały reset
  `* { margin: 0; padding: 0; box-sizing: border-box }` z treści każdej strony.
  Nie zależy od żadnej zmiennej :root strony — własne zmienne --pt-* zdefiniowane
  lokalnie na .pt-header i .pt-footer (nie na :root), żeby żadna strona nie mogła
  ich nadpisać swoim resetem czy swoimi zmiennymi.
*/

.pt-header {
  --pt-bg: #0a0a0a;
  --pt-bg-alt: #141414;
  --pt-text: #ffffff;
  --pt-text-dim: #a0a0a0;
  --pt-accent: #e80404;
  --pt-border: rgba(255, 255, 255, 0.1);

  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  background: var(--pt-bg);
  border-bottom: 1px solid var(--pt-border);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  position: sticky;
  top: 0;
  left: 0;
  z-index: 9999;
  box-sizing: border-box;
}

.pt-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 24px;
  box-sizing: border-box;
  position: relative;
}

.pt-logo {
  display: inline-block;
  margin: 0;
  padding: 0;
  line-height: 0;
  text-decoration: none;
  flex-shrink: 0;
}

.pt-logo-img {
  display: block;
  width: 180px;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
}

.pt-logo:hover {
  opacity: 0.9;
}

/* Strona główna: pasek leży NA zdjęciu i jest przezroczysty, dopiero po zjechaniu
   robi się czarny. W oryginale zdjęcie jest tłem samego nagłówka — u nas nagłówek
   jest wspólny dla 12 stron, więc zamiast tego kładziemy go na sekcji hero.
   Klasę .pt-home ma tylko strona główna; podstrony zostają z czarnym paskiem. */
.pt-home .pt-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: transparent;
  border-bottom-color: transparent;
  transition: background 0.25s ease, border-color 0.25s ease;
}

.pt-home .pt-header.pt-header-solid {
  background: var(--pt-bg);
  border-bottom-color: var(--pt-border);
}

/* Na samej górze pasek jest wyższy — w oryginale 113 px; po zjechaniu ścieśnia się */
.pt-home .pt-header:not(.pt-header-solid) .pt-header-inner {
  padding-top: 30px;
  padding-bottom: 30px;
}

/* Bez JavaScriptu (wyłączony, stary silnik) pasek zostaje czytelny dzięki cieniowi */
.pt-home .pt-header:not(.pt-header-solid) .pt-nav-list,
.pt-home .pt-header:not(.pt-header-solid) .pt-logo {
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.6);
}

/* Przełącznik menu mobilnego — czysty CSS, bez JavaScriptu (checkbox hack) */
.pt-nav-toggle {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.pt-nav-toggle-label {
  display: none;
  width: 32px;
  height: 32px;
  padding: 4px;
  margin: 0;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  box-sizing: border-box;
}

.pt-nav-toggle-label span {
  display: block;
  width: 24px;
  height: 2px;
  margin: 0;
  padding: 0;
  background: var(--pt-text);
  border-radius: 2px;
}

.pt-nav {
  margin: 0;
  padding: 0;
}

.pt-nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 4px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pt-nav-item {
  margin: 0;
  padding: 0;
  list-style: none;
}

.pt-nav-link {
  display: inline-block;
  margin: 0;
  padding: 8px 4px;
  color: var(--pt-text);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.pt-nav-link:hover {
  color: var(--pt-accent);
}

/* Rozwijane listy — jak w oryginale: biały panel, ciemne pozycje, strzałka przy rodzicu */
.pt-nav-item.pt-has-sub {
  position: relative;
}

.pt-has-sub > .pt-nav-link::after {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  margin: 0 0 2px 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  vertical-align: middle;
}

.pt-subnav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 240px;
  margin: 0;
  padding: 12px 0;
  list-style: none;
  background: #ffffff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  z-index: 10000;
}

.pt-has-sub:hover > .pt-subnav,
.pt-has-sub:focus-within > .pt-subnav {
  display: block;
}

.pt-subnav-item {
  margin: 0;
  padding: 0;
  list-style: none;
}

.pt-subnav-link {
  display: block;
  margin: 0;
  padding: 10px 24px;
  color: #6f6f6f;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.pt-subnav-link:hover,
.pt-subnav-link:focus {
  color: var(--pt-accent);
}

/* Mobile: hamburger poniżej 900px */
@media (max-width: 900px) {
  .pt-nav-toggle-label {
    display: flex;
  }

  .pt-nav {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--pt-bg-alt);
    border-bottom: 1px solid var(--pt-border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }

  .pt-nav-toggle:checked ~ .pt-nav {
    max-height: 760px;
  }

  /* Zwinięte menu ma max-height: 0, ale jego dolna ramka tworzy pasek 1 px, a tło
     elementu maluje się TAKŻE pod ramką (background-clip sięga domyślnie do krawędzi
     obramowania). Sam przezroczysty kolor ramki nie wystarczył — zostawał ciemny pasek
     tła i kreska w poprzek zdjęcia dalej była widoczna. Dlatego w stanie zwiniętym
     zdejmujemy ramkę w całości i tło. Jedno i drugie wraca przy rozwiniętym menu. */
  .pt-nav-toggle:not(:checked) ~ .pt-nav {
    border-bottom-width: 0;
    background: transparent;
  }

  .pt-nav-list {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: 8px 24px 16px;
    box-sizing: border-box;
  }

  .pt-nav-item {
    width: 100%;
    box-sizing: border-box;
  }

  .pt-nav-link {
    display: block;
    width: 100%;
    padding: 12px 4px;
    box-sizing: border-box;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  .pt-nav-toggle:checked ~ .pt-nav .pt-subnav,
  .pt-subnav {
    display: block;
    position: static;
    min-width: 0;
    padding: 0 0 4px 16px;
    background: transparent;
    box-shadow: none;
  }

  .pt-subnav-link {
    padding: 10px 4px;
    color: var(--pt-text-dim);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  .pt-has-sub > .pt-nav-link::after {
    display: none;
  }
}

/* ============================================================ */

.pt-footer {
  --pt-bg: #0a0a0a;
  --pt-text: #ffffff;
  --pt-text-dim: #a0a0a0;
  --pt-accent: #e80404;
  --pt-border: rgba(255, 255, 255, 0.1);

  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  background: var(--pt-bg);
  border-top: 1px solid var(--pt-border);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  box-sizing: border-box;
}

.pt-footer-inner {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 32px 24px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 48px 24px 24px;
  box-sizing: border-box;
}

@media (max-width: 900px) {
  .pt-footer-inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .pt-footer-inner {
    grid-template-columns: 1fr;
  }
}

.pt-footer-col {
  margin: 0;
  padding: 0;
}

.pt-footer-heading {
  margin: 0 0 16px 0;
  padding: 0;
  font-size: 16px;
  line-height: 1.3;
  font-weight: 700;
  color: var(--pt-text);
}

.pt-footer-text {
  margin: 0 0 10px 0;
  padding: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--pt-text-dim);
}

.pt-footer-link {
  color: var(--pt-text-dim);
  text-decoration: none;
}

.pt-footer-link:hover {
  color: var(--pt-accent);
}

.pt-footer-bottom {
  margin: 0;
  padding: 20px 24px;
  border-top: 1px solid var(--pt-border);
  text-align: center;
  box-sizing: border-box;
}

.pt-footer-note {
  margin: 0;
  padding: 0;
  font-size: 13px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.4);
}
