/* Publiczne aktualności: treść i albumy otwierane na stronie Szczepu 444. */
.fb-feed,
.fb-feed__row,
.fb-feed .fb-post,
.fb-feed .fb-post__body {
  min-width: 0;
}

.fb-feed .fb-post {
  transition: border-color 180ms ease, background-color 180ms ease;
}

.fb-feed .fb-post:hover {
  border-color: rgba(231, 198, 107, 0.45);
  background-color: rgba(18, 20, 22, 0.88);
}

.fb-feed .fb-post__link,
.fb-feed .fb-post-open,
.fb-feed .news-thumb-button,
.fb-feed .news-read {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.fb-feed .fb-post__link {
  min-width: 0;
  box-shadow: none;
  transform: none;
}

.fb-feed .fb-post__link:hover {
  box-shadow: none;
  transform: none;
}

.fb-feed .fb-post--big {
  display: grid;
  grid-template-columns: minmax(0, 58fr) minmax(0, 42fr);
}

.fb-feed .fb-post--big .fb-post__body {
  justify-content: center;
}

.fb-feed .fb-post--big .fb-post__cta {
  margin-top: 12px;
}

.fb-feed button:focus-visible,
.fb-dialog button:focus-visible {
  outline: 3px solid var(--color-gold-soft, #e7c66b);
  outline-offset: -4px;
}

.fb-feed .fb-post__img,
.fb-feed .news-thumb-wrap {
  position: relative;
  min-width: 0;
  overflow: hidden;
  isolation: isolate;
  background: #181b1e;
}

.fb-feed .news-thumb-button {
  position: absolute;
  inset: 0;
  display: block;
  min-height: 0;
  height: 100%;
}

.fb-feed .news-thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transition: opacity 220ms ease;
}

.fb-feed .is-loaded .news-thumb,
.fb-dialog .is-loaded .fb-gallery-image {
  opacity: 1;
}

.fb-feed .fb-post__text {
  overflow-wrap: anywhere;
}

.fb-feed .fb-post__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-top: 8px;
}

.fb-feed .fb-post__cta::after {
  content: "→";
  font-family: var(--font-body, sans-serif);
  font-size: 17px;
  line-height: 1;
}

.fb-image-state,
.fb-feed-loading,
.fb-feed-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  color: rgba(255, 255, 255, 0.8);
  text-align: center;
}

.fb-image-state {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(ellipse at 50% 40%, #272b2c 0%, #171a1d 75%);
}

.fb-feed-loading,
.fb-feed-error {
  min-height: 260px;
  border: 1px solid var(--glass-border, rgba(255, 255, 255, 0.14));
  border-radius: var(--radius-md, 16px);
  background: var(--glass-bg-strong, rgba(12, 14, 16, 0.62));
}

.fb-image-state[hidden],
.fb-feed-loading[hidden] {
  display: none !important;
}

.fb-loading-logo {
  display: block;
  width: clamp(64px, 12vw, 104px);
  height: 80px;
  max-width: 50%;
  object-fit: contain;
  opacity: 0.7;
  animation: fb-logo-pulse 1500ms ease-in-out infinite;
  pointer-events: none;
}

.fb-image-message {
  max-width: 35ch;
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  font: 400 13px/1.5 var(--font-body, "Segoe UI", sans-serif);
  overflow-wrap: anywhere;
}

.fb-image-retry {
  -webkit-appearance: none;
  appearance: none;
  min-height: 42px;
  max-width: 100%;
  padding: 8px 17px;
  border: 1px solid rgba(231, 198, 107, 0.55);
  border-radius: 999px;
  background: rgba(231, 198, 107, 0.08);
  color: var(--color-gold-soft, #e7c66b);
  font: 600 13px/1.4 var(--font-body, "Segoe UI", sans-serif);
  cursor: pointer;
}

.fb-image-retry:hover {
  background: rgba(231, 198, 107, 0.17);
}

.fb-feed .news-thumb-wrap > .fb-image-retry,
.fb-dialog .fb-gallery-item > .fb-image-retry {
  position: absolute;
  z-index: 2;
  left: 50%;
  bottom: 18px;
  width: max-content;
  max-width: calc(100% - 32px);
  transform: translateX(-50%);
}

.fb-feed .is-error .fb-image-state,
.fb-dialog .is-error .fb-image-state {
  padding-top: 16px;
  padding-bottom: 72px;
}

.is-error > .fb-image-state .fb-loading-logo,
.fb-feed .is-error .fb-loading-logo,
.fb-feed-loading.is-error .fb-loading-logo,
.fb-feed-error .fb-loading-logo,
.fb-feed .is-empty .fb-loading-logo {
  animation: none;
  opacity: 0.45;
}

@keyframes fb-logo-pulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 0.85; }
}

.fb-dialog {
  position: fixed;
  inset: 0;
  width: min(1000px, calc(100vw - 48px));
  max-width: 100%;
  max-height: min(90vh, calc(100vh - 48px));
  max-height: min(90dvh, calc(100dvh - 48px));
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 22px;
  background: #121518;
  color: #fff;
  font-family: var(--font-body, "Segoe UI", sans-serif);
  box-shadow: 0 24px 90px rgba(0, 0, 0, 0.7);
  overscroll-behavior: contain;
}

.fb-dialog::backdrop {
  background: rgba(3, 5, 6, 0.84);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.fb-dialog__panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-height: min(calc(90vh - 2px), calc(100vh - 50px));
  max-height: min(calc(90dvh - 2px), calc(100dvh - 50px));
}

.fb-dialog__header {
  position: relative;
  z-index: 2;
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-width: 0;
  padding: 21px 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  background: #191c1f;
}

.fb-dialog__heading {
  margin: 0;
  font: 500 clamp(22px, 3vw, 29px)/1.2 var(--font-head, "Arial Narrow", sans-serif);
  letter-spacing: 0.3px;
  overflow-wrap: anywhere;
}

.fb-dialog__date {
  display: block;
  margin-top: 5px;
  color: var(--color-gold-soft, #e7c66b);
  font-size: 13px;
  line-height: 1.4;
}

.fb-dialog__close {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 9px 14px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font: 500 13px/1.4 var(--font-body, "Segoe UI", sans-serif);
  cursor: pointer;
}

.fb-dialog__close:hover {
  border-color: rgba(231, 198, 107, 0.7);
  background: rgba(255, 255, 255, 0.12);
}

.fb-dialog__body {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  padding: 28px;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior-y: contain;
  scrollbar-width: thin;
  scrollbar-color: #686a65 #191c1f;
  -webkit-overflow-scrolling: touch;
}

.fb-dialog__text {
  margin: 0;
  color: rgba(255, 255, 255, 0.94);
  font-size: clamp(15px, 1.8vw, 17px);
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.fb-dialog__text:empty {
  display: none;
}

.fb-dialog__gallery {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  margin-top: 26px;
}

.fb-dialog__gallery:empty {
  display: none;
}

.fb-gallery-item {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 260px;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: #0b0d0f;
  isolation: isolate;
}

.fb-gallery-image {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  max-height: 78vh;
  max-height: 78dvh;
  object-fit: contain;
  opacity: 0;
  transition: opacity 220ms ease;
}

.fb-gallery-open {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: inherit;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: zoom-in;
  -webkit-tap-highlight-color: transparent;
}

.fb-lightbox {
  position: fixed;
  inset: 0;
  width: 100vw;
  max-width: none;
  height: 100vh;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #07090b;
  color: #fff;
  font-family: var(--font-body, "Segoe UI", sans-serif);
  overscroll-behavior: contain;
}

.fb-lightbox[open] {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.fb-lightbox::backdrop {
  background: #07090b;
}

.fb-lightbox__header {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 16px;
  min-width: 0;
  padding: calc(12px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) 12px max(16px, env(safe-area-inset-left, 0px));
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  background: #14181b;
}

.fb-lightbox__label {
  display: flex;
  align-items: baseline;
  gap: 16px;
  min-width: 0;
}

.fb-lightbox__title {
  margin: 0;
  font-size: 19px;
  font-weight: 600;
}

.fb-lightbox__counter {
  color: var(--color-gold-soft, #e7c66b);
  font-size: 14px;
  white-space: nowrap;
}

.fb-lightbox__zoom {
  display: flex;
  align-items: center;
  gap: 4px;
}

.fb-lightbox__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.23);
  border-radius: 10px;
  background: #202529;
  color: #fff;
  font: 600 20px/1.2 var(--font-body, "Segoe UI", sans-serif);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.fb-lightbox__button:hover:not(:disabled) {
  border-color: var(--color-gold-soft, #e7c66b);
  background: #303634;
}

.fb-lightbox__button:disabled {
  opacity: 0.35;
  cursor: default;
}

.fb-lightbox button:focus-visible,
.fb-lightbox__viewport:focus-visible {
  outline: 3px solid var(--color-gold-soft, #e7c66b);
  outline-offset: -4px;
}

.fb-lightbox-zoom-reset {
  min-width: 60px;
  font-size: 13px;
}

.fb-lightbox-close {
  padding-inline: 14px;
  font-size: 13px;
}

.fb-lightbox__viewer {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.fb-lightbox__viewport {
  width: 100%;
  height: 100%;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #777 #111;
  -webkit-overflow-scrolling: touch;
}

.fb-lightbox__stage {
  width: 100%;
  height: 100%;
  min-width: 100%;
  min-height: 100%;
}

.fb-lightbox__figure {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  margin: 0;
  isolation: isolate;
}

.fb-lightbox__image {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: contain;
  opacity: 0;
}

.fb-lightbox .is-loaded .fb-lightbox__image {
  opacity: 1;
}

.fb-lightbox .fb-image-state {
  background: #0e1215;
}

.fb-lightbox .fb-image-retry {
  position: absolute;
  z-index: 2;
  left: 50%;
  top: calc(50% + 82px);
  max-width: calc(100% - 100px);
  transform: translateX(-50%);
}

.fb-lightbox__arrow {
  position: absolute;
  z-index: 2;
  top: 50%;
  min-width: 48px;
  min-height: 56px;
  border-radius: 12px;
  background: rgba(22, 27, 30, 0.86);
  font-size: 38px;
  transform: translateY(-50%);
}

.fb-lightbox-previous {
  left: max(12px, env(safe-area-inset-left, 0px));
}

.fb-lightbox-next {
  right: max(12px, env(safe-area-inset-right, 0px));
}

.fb-lightbox__hint {
  margin: 0;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
  color: rgba(255, 255, 255, 0.65);
  background: #14181b;
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
}

@media (max-width: 600px) {
  .fb-lightbox__header {
    gap: 6px;
    padding-inline: max(8px, env(safe-area-inset-left, 0px)) max(8px, env(safe-area-inset-right, 0px));
  }

  .fb-lightbox__title {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .fb-lightbox__counter {
    font-size: 12px;
  }

  .fb-lightbox__zoom {
    gap: 2px;
  }

  .fb-lightbox-zoom-reset {
    min-width: 54px;
    padding-inline: 5px;
  }

  .fb-lightbox-close {
    padding-inline: 9px;
  }

  .fb-lightbox__arrow {
    min-width: 44px;
    min-height: 48px;
  }

  .fb-lightbox-previous {
    left: max(5px, env(safe-area-inset-left, 0px));
  }

  .fb-lightbox-next {
    right: max(5px, env(safe-area-inset-right, 0px));
  }
}

.fb-post__media-label {
  position: absolute;
  z-index: 2;
  left: 14px;
  top: 14px;
  max-width: calc(100% - 28px);
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(8, 10, 12, 0.82);
  color: #fff;
  font: 600 12px/1.4 var(--font-body, "Segoe UI", sans-serif);
  pointer-events: none;
}

.fb-shared,
.fb-video-item,
.fb-embed {
  min-width: 0;
  margin: 24px 0 0;
}

.fb-shared {
  padding: 20px;
  border: 1px solid rgba(231, 198, 107, 0.25);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
}

.fb-shared__label {
  margin: 0 0 8px;
  color: var(--color-gold-soft, #e7c66b);
  font-size: 12px;
  font-weight: 600;
}

.fb-shared__title {
  margin: 0;
  color: #fff;
  font-size: clamp(18px, 2.5vw, 24px);
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.fb-shared__description {
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.65;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.fb-video {
  display: block;
  width: 100%;
  max-height: 70vh;
  max-height: 70dvh;
  min-height: 180px;
  border-radius: 12px;
  background: #050607;
}

.fb-media-notice {
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.fb-embed__stage {
  position: relative;
  margin-top: 14px;
  width: min(100%, 500px);
  min-width: 0;
}

.fb-embed__stage[hidden],
.fb-embed__loading[hidden],
.fb-embed-load[hidden] {
  display: none !important;
}

.fb-embed__loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 120px;
  padding: 14px;
}

.fb-embed__frame {
  display: block;
  max-width: 100%;
  width: 100%;
  border: 0;
  border-radius: 8px;
  background: #fff;
}

.fb-embed--video .fb-embed__frame {
  height: auto;
  min-height: 260px;
  aspect-ratio: 16 / 9;
}

@media (max-width: 900px) {
  .fb-feed .fb-post--big {
    display: flex;
  }

  .fb-feed .fb-post--big .fb-post__link {
    flex-direction: column;
  }

  .fb-feed .fb-post--big .fb-post__img {
    flex: none;
    width: 100%;
    min-height: 0;
    aspect-ratio: 16 / 10;
  }

  .fb-feed .fb-post--small .fb-post__img {
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 600px) {
  .fb-dialog {
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
    max-height: calc(100dvh - 20px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
    border-radius: 16px;
  }

  .fb-dialog__panel {
    max-height: calc(100vh - 22px);
    max-height: calc(100dvh - 22px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
  }

  .fb-dialog__header {
    gap: 12px;
    padding: 16px;
  }

  .fb-dialog__heading {
    font-size: 22px;
  }

  .fb-dialog__body {
    padding: 20px 16px;
  }

  .fb-dialog__gallery {
    gap: 12px;
    margin-top: 20px;
  }

  .fb-gallery-item {
    min-height: 200px;
    border-radius: 9px;
  }

  .fb-feed .fb-post__body {
    padding: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .fb-loading-logo {
    animation: none;
    opacity: 0.7;
  }

  .fb-feed .fb-post,
  .fb-feed .news-thumb,
  .fb-dialog .fb-gallery-image {
    transition: none;
  }
}
