/* Footer v2 + Crisis bar */
.crisis-bar{padding:12px 0;border-top:1px solid rgba(255,255,255,.12);border-bottom:1px solid rgba(255,255,255,.12)}
.crisis-inner{display:flex;gap:16px;align-items:center;justify-content:space-between;flex-wrap:wrap}
.crisis-text{margin:0;font-size:13px;line-height:1.35;opacity:.95}
.crisis-link{white-space:nowrap;font-weight:700;text-decoration:underline}

.site-footer{padding:26px 0 14px 0;border-top:1px solid rgba(255,255,255,.12)}
.footer-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:22px}
.footer-col-title{margin:0 0 10px 0;font-size:14px;font-weight:800;letter-spacing:.02em}
.footer-links{list-style:none;margin:0;padding:0;display:grid;gap:8px}
.footer-links a{text-decoration:none;opacity:.9}
.footer-links a:hover{opacity:1;text-decoration:underline}
.footer-soon{font-size:12px;opacity:.7;margin-left:6px}
.footer-acc-btn{display:none;align-items:center;justify-content:space-between;width:100%;border:0;background:transparent;padding:10px 0;font-weight:800;cursor:pointer}
.footer-acc-icon{font-weight:900;opacity:.8}

.sub-footer{margin-top:18px;padding-top:12px;border-top:1px solid rgba(255,255,255,.12);display:flex;gap:14px;flex-wrap:wrap;justify-content:space-between;font-size:12px;opacity:.9}
.sub-footer a{text-decoration:underline;opacity:.95}

@media (max-width: 980px){
  .footer-grid{grid-template-columns:1fr}
  .footer-col-title{display:none}
  .footer-acc-btn{display:flex}
  .footer-links{display:none;padding-bottom:10px}
  .footer-col.is-open .footer-links{display:grid}
}


/* AI-MED FOOTER COLLAPSE v1 */
footer .footer-collapsible > ul,
footer .footer-collapsible > ol,
footer .footer-collapsible > .footer-links,
footer .footer-collapsible > .links {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  margin-top: 0;
  transition: max-height .25s ease, opacity .2s ease, margin-top .2s ease;
}

/* Pokaż linki: hover (desktop), focus (klawiatura), is-open (klik na mobile) */
footer .footer-collapsible:hover > ul,
footer .footer-collapsible:hover > ol,
footer .footer-collapsible:hover > .footer-links,
footer .footer-collapsible:hover > .links,
footer .footer-collapsible:focus-within > ul,
footer .footer-collapsible:focus-within > ol,
footer .footer-collapsible:focus-within > .footer-links,
footer .footer-collapsible:focus-within > .links,
footer .footer-collapsible.is-open > ul,
footer .footer-collapsible.is-open > ol,
footer .footer-collapsible.is-open > .footer-links,
footer .footer-collapsible.is-open > .links {
  max-height: 600px;     /* wystarczy na ~30 linków */
  opacity: 1;
  pointer-events: auto;
  margin-top: 10px;
}

footer .footer-collapsible > h2,
footer .footer-collapsible > h3,
footer .footer-collapsible > h4,
footer .footer-collapsible > h5 {
  cursor: pointer;
}

/* Na urządzeniach dotykowych: hover nie istnieje, więc otwieranie przez klik (klasa is-open) */
@media (hover: none) {
  footer .footer-collapsible:hover > ul,
  footer .footer-collapsible:hover > ol,
  footer .footer-collapsible:hover > .footer-links,
  footer .footer-collapsible:hover > .links {
    max-height: 0;
    opacity: 0;
    pointer-events: none;
    margin-top: 0;
  }
}



/* AI-MED FOOTER COLLAPSE v2 */
/* Ukryj zawartość kolumny (linki) – pokaż dopiero po hover/focus lub po kliknięciu (is-open) */
footer .footer-collapsible .footer-collapsible-body{
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  margin-top: 0;
  transition: max-height .25s ease, opacity .2s ease, margin-top .2s ease;
}

footer .footer-collapsible:hover .footer-collapsible-body,
footer .footer-collapsible:focus-within .footer-collapsible-body,
footer .footer-collapsible.is-open .footer-collapsible-body{
  max-height: 800px;
  opacity: 1;
  pointer-events: auto;
  margin-top: 10px;
}

footer .footer-collapsible .footer-collapsible-title{
  cursor: pointer;
}

/* Na dotykowych: hover nie działa → zostaje klik (is-open) */
@media (hover: none){
  footer .footer-collapsible:hover .footer-collapsible-body{
    max-height: 0;
    opacity: 0;
    pointer-events: none;
    margin-top: 0;
  }
}


/* === AI-MED FOOTER COLLAPSE v2 FIX: na desktop klik nie "przykleja" kolumny === */
@media (hover: hover){
  footer .footer-collapsible.is-open .footer-collapsible-body{
    max-height: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
    margin-top: 0 !important;
  }
}


/* AI-MED FOOTER COLLAPSE v3 FIX */
/* 1) Desktop: klik/focus nie mają utrzymywać otwartej kolumny (tylko hover) */
@media (hover: hover) {
  footer .footer-collapsible.is-open .footer-collapsible-body,
  footer .footer-collapsible:focus-within .footer-collapsible-body {
    max-height: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
    margin-top: 0 !important;
  }
}

/* 2) Koniec "skakania" layoutu: rezerwuj miejsce na scrollbar */
html {
  scrollbar-gutter: stable;
}
body {
  overflow-y: scroll;
}



/* AI-MED FOOTER COLLAPSE v4 ACCORDION */
/* Stabilny układ (koniec “skakania” przez scrollbar) */
html { scrollbar-gutter: stable; }
body { overflow-y: scroll; }

/* Domyślnie ukryj zawartość kolumn */
footer .footer-collapsible .footer-collapsible-body {
  max-height: 0 !important;
  opacity: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
  margin-top: 0 !important;
  transition: max-height .25s ease, opacity .2s ease, margin-top .2s ease;
}

/* Pokaż tylko gdy kolumna ma is-open */
footer .footer-collapsible.is-open .footer-collapsible-body {
  max-height: 900px !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  margin-top: 10px !important;
}

/* Wyłącz “otwieranie” hover/focus (żeby nie było dwóch kolumn naraz) */
footer .footer-collapsible:hover .footer-collapsible-body,
footer .footer-collapsible:focus-within .footer-collapsible-body {
  max-height: 0 !important;
  opacity: 0 !important;
  pointer-events: none !important;
  margin-top: 0 !important;
}

footer .footer-collapsible .footer-collapsible-title {
  cursor: pointer;
}



/* AI-MED FOOTER COLLAPSE v5 ACCORDION */
/* Koniec “skakania” layoutu przez scrollbar */
html { scrollbar-gutter: stable; }
body { overflow-y: scroll; }

/* Ukryj plusikowy przycisk (chcesz widzieć tylko tytuły) */
.site-footer .footer-acc-btn{ display:none !important; }

/* Tytuł ma wyglądać jak element klikalny */
.site-footer .footer-col-title{ cursor:pointer; }

/* Domyślnie: ukryj linki */
.site-footer .footer-col .footer-links{
  display:none !important;
  margin-top: 10px;
}

/* Pokaż linki tylko w otwartej kolumnie */
.site-footer .footer-col.is-open .footer-links{
  display:block !important;
}



/* AI-MED FOOTER COLLAPSE v5.1 ACCORDION */
/* Stabilny układ (koniec “skakania”) */
html { scrollbar-gutter: stable; }
body { overflow-y: scroll; }

/* Ukryj przycisk + (zostają same tytuły) */
.site-footer .footer-acc-btn{ display:none !important; }

/* Tytuł wygląda jak klikalny */
.site-footer .footer-col-title{ cursor:pointer !important; }

/* Domyślnie ukryj linki */
.site-footer .footer-col .footer-links{
  display:none !important;
  margin-top:10px !important;
}

/* Pokaż linki tylko w otwartej kolumnie */
.site-footer .footer-col.is-open .footer-links{
  display:block !important;

  /* reset po wcześniejszych wersjach (gdyby UL dostał footer-collapsible-body) */
  max-height:none !important;
  opacity:1 !important;
  overflow:visible !important;
  pointer-events:auto !important;
}

