/* Baner zgody na cookies (RODO). Własny, odizolowany zestaw klas .epcc-*, niezależny od motywu strony. */
.epcc, .epcc *, .epcc-embed, .epcc-embed * { box-sizing: border-box; }
.epcc, .epcc-embed {
  font-family: 'Outfit', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  color: #F0F0FF;
  cursor: auto; /* strona /oferta chowa kursor systemowy: w oknie zgody ma być widoczny */
}
.epcc button, .epcc a, .epcc summary, .epcc label, .epcc-embed button, .epcc-embed a { cursor: pointer; }

html.epcc-lock { overflow: hidden; }

/* ── baner ── */
.epcc-banner {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  width: min(1000px, calc(100% - 32px));
  z-index: 100000;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem 1.6rem;
  align-items: center;
  padding: 1.15rem 1.35rem;
  background: rgba(12, 12, 30, .985);
  border: 1px solid rgba(154, 77, 255, .5);
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .65), 0 0 0 1px rgba(0, 207, 255, .08);
  animation: epcc-in .35s ease-out both;
}
.epcc-banner.epcc-away { display: none; }
.epcc-modal:focus { outline: none; }
@keyframes epcc-in { from { opacity: 0; transform: translate(-50%, 14px); } to { opacity: 1; transform: translate(-50%, 0); } }

.epcc-title { margin: 0 0 .3rem; font-size: 1.05rem; font-weight: 700; color: #fff; letter-spacing: .01em; }
.epcc-text { margin: 0 0 .5rem; color: #C9C9E6; font-size: .86rem; white-space: pre-line; }
.epcc-link { color: #00CFFF; font-size: .84rem; text-decoration: underline; text-underline-offset: 3px; }
.epcc-link:hover { color: #fff; }

.epcc-actions { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: flex-end; }

/* przyciski: "odrzuć" i "zaakceptuj" mają ten sam rozmiar i wagę (równa łatwość odmowy i zgody) */
.epcc-btn {
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
  font-weight: 600;
  font-size: .88rem;
  line-height: 1.2;
  min-height: 44px;
  padding: .7rem 1.25rem;
  border-radius: 40px;
  border: 1px solid rgba(255, 255, 255, .4);
  background: #1a1a3a;
  color: #fff;
  white-space: nowrap;
  transition: transform .15s, border-color .2s, background .2s;
}
.epcc-btn:hover { border-color: #fff; transform: translateY(-1px); }
.epcc-primary { background: linear-gradient(90deg, #9A4DFF, #FF3EBF); border-color: transparent; }
.epcc-primary:hover { border-color: transparent; filter: brightness(1.1); }
.epcc-ghost { background: transparent; border-color: rgba(154, 77, 255, .7); }
.epcc :focus-visible, .epcc-embed :focus-visible { outline: 2px solid #00CFFF; outline-offset: 2px; }
.epcc .epcc-modal:focus, .epcc .epcc-modal:focus-visible { outline: none; }

/* ── okno ustawień ── */
.epcc-overlay {
  position: fixed;
  inset: 0;
  z-index: 100001;
  background: rgba(2, 2, 10, .72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: epcc-fade .2s ease-out both;
}
@keyframes epcc-fade { from { opacity: 0; } to { opacity: 1; } }
.epcc-modal {
  width: min(720px, 100%);
  max-height: min(88vh, 860px);
  display: flex;
  flex-direction: column;
  background: #0d0d24;
  border: 1px solid rgba(154, 77, 255, .5);
  border-radius: 20px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, .7);
  overflow: hidden;
}
.epcc-mhead { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.4rem; border-bottom: 1px solid rgba(154, 77, 255, .25); }
.epcc-mhead .epcc-title { margin: 0; font-size: 1.15rem; }
.epcc-x { appearance: none; background: transparent; border: 0; color: #C9C9E6; font-size: 1.8rem; line-height: 1; width: 40px; height: 40px; border-radius: 50%; }
.epcc-x:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.epcc-mbody { padding: 1rem 1.4rem; overflow-y: auto; flex: 1; }
.epcc-intro { margin: 0 0 1rem; color: #C9C9E6; font-size: .86rem; }
.epcc-cat { padding: .9rem 0; border-top: 1px solid rgba(154, 77, 255, .2); }
.epcc-cat:first-of-type { border-top: 0; }
.epcc-cathead { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.epcc-cathead h3 { margin: 0; font-size: 1rem; font-weight: 700; color: #fff; }
.epcc-cat p { margin: .35rem 0 0; color: #C9C9E6; font-size: .84rem; }
.epcc-always { font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: #00CFFF; white-space: nowrap; }
.epcc-polrow { margin: .8rem 0 0; }

.epcc-switch { position: relative; display: inline-block; width: 50px; height: 28px; flex-shrink: 0; }
.epcc-switch input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; z-index: 2; }
.epcc-slider { position: absolute; inset: 0; border-radius: 28px; background: #3a3a63; transition: background .2s; }
.epcc-slider::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: transform .2s; }
.epcc-switch input:checked + .epcc-slider { background: linear-gradient(90deg, #9A4DFF, #FF3EBF); }
.epcc-switch input:checked + .epcc-slider::after { transform: translateX(22px); }
.epcc-switch input:focus-visible + .epcc-slider { outline: 2px solid #00CFFF; outline-offset: 2px; }

.epcc-details { margin-top: .55rem; }
.epcc-details summary { color: #00CFFF; font-size: .8rem; list-style: none; display: inline-block; text-decoration: underline; text-underline-offset: 3px; }
.epcc-details summary::-webkit-details-marker { display: none; }
.epcc-tablewrap { overflow-x: auto; margin-top: .5rem; }
.epcc-table { width: 100%; border-collapse: collapse; font-size: .76rem; color: #C9C9E6; }
.epcc-table th, .epcc-table td { text-align: left; padding: .45rem .55rem; border-bottom: 1px solid rgba(154, 77, 255, .18); vertical-align: top; }
.epcc-table th { color: #fff; font-weight: 600; white-space: nowrap; }
.epcc-cn { word-break: break-word; color: #fff; }

.epcc-mfoot { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: flex-end; padding: 1rem 1.4rem; border-top: 1px solid rgba(154, 77, 255, .25); background: #0a0a1e; }

/* ── ikona ponownego otwarcia ustawień ── */
.epcc-fab {
  position: fixed;
  left: 14px;
  bottom: 14px;
  z-index: 99990;
  width: 44px;
  height: 44px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid rgba(154, 77, 255, .65);
  background: #12122b;
  font-size: 20px;
  line-height: 1;
  box-shadow: 0 8px 26px rgba(0, 0, 0, .5);
  transition: transform .15s, border-color .2s;
}
.epcc-fab:hover { transform: scale(1.07); border-color: #fff; }

/* ── zaślepka treści zewnętrznej (np. film YouTube) ── */
.epcc-embed {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 160px;
  padding: 1rem;
  background: #0c0c1e;
  border: 1px dashed rgba(154, 77, 255, .55);
  border-radius: 10px;
}
.epcc-embed-in p { margin: 0 0 .8rem; font-size: .84rem; color: #C9C9E6; }
.epcc-embed .epcc-btn { min-height: 40px; padding: .55rem 1rem; font-size: .82rem; margin: 0 .3rem .4rem 0; }
.epcc-embed .epcc-link { display: inline-block; margin-top: .3rem; }

@media (max-width: 720px) {
  .epcc-banner { grid-template-columns: 1fr; bottom: 10px; width: calc(100% - 20px); padding: 1rem; max-height: calc(100vh - 20px); overflow-y: auto; }
  /* kolejność jak w kodzie: odrzuć, ustawienia, zaakceptuj (odmowa nie jest schowana pod zgodą) */
  .epcc-actions { flex-direction: column; align-items: stretch; }
  .epcc-btn { width: 100%; text-align: center; white-space: normal; }
  .epcc-mfoot { flex-direction: column; }
  .epcc-fab { bottom: 78px; left: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .epcc-banner, .epcc-overlay { animation: none; }
  .epcc-btn, .epcc-fab, .epcc-slider, .epcc-slider::after { transition: none; }
}
