/* cookies-zgody-v2: baner cookies (1. poziom) i ustawienia (2. poziom) - partials/cookie-consent.blade.php, public/js/cookie-consent.js.
   Telefon i tablet (< 1024 px): dolny arkusz nad #mobile-bottom-nav (58 px przy <= 768 px), bez przyciemnienia.
   Komputer (>= 1024 px): pasek przyklejony do dołu, ustawienia jako okno 560 px z przyciemnieniem.
   Wszystko position: fixed - bez przesunięć układu (CLS). */

/* stary pasek whcookies.js (#cookies-message) w nowym systemie niewidoczny */
#cookies-message-container, #cookies-message { display: none !important; }

.sc-cc, .sc-cc-ust, .sc-cc-tlo { box-sizing: border-box; font-family: 'Barlow', 'Open Sans', Arial, sans-serif; }
.sc-cc *, .sc-cc-ust * { box-sizing: border-box; }
.sc-cc[hidden], .sc-cc-ust[hidden], .sc-cc-tlo[hidden] { display: none !important; }

.sc-cc {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1040;
  background: #111a24; color: #e8edf2;
  border-top: 2px solid #f5a623; border-radius: 16px 16px 0 0;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, .35);
  padding: 18px 16px;
}
/* fokus ustawiany z JS po pokazaniu banera - bez obrysu kontenera (obrys mają przyciski i linki) */
.sc-cc-baner, .sc-cc-baner:focus, .sc-cc-baner:focus-visible { outline: none; }
.sc-cc-glowa { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.sc-cc-ikona { flex: 0 0 auto; color: #f5a623; }
.sc-cc-tytul { font-size: 17px; font-weight: 600; line-height: 1.3; color: #e8edf2; }
.sc-cc-tresc p { margin: 0 0 8px; font-size: 13.5px; line-height: 1.5; color: #c5cfd9; }
.sc-cc a, .sc-cc-ust a { color: #f5a623; text-decoration: underline; }
.sc-cc a:hover, .sc-cc-ust a:hover { color: #ffbf4d; }

.sc-cc-przyciski { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.sc-cc-btn-ust { grid-column: 1 / -1; }

.sc-cc-btn {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  min-height: 48px; padding: 6px 12px; margin: 0;
  border-radius: 8px; cursor: pointer;
  font: 600 15px/1.2 'Barlow', 'Open Sans', Arial, sans-serif; letter-spacing: 0;
  white-space: normal; overflow-wrap: anywhere; text-transform: none;
}
/* Odrzucam i Akceptuję - ten sam styl (równorzędne) */
.sc-cc-btn-gl { background: #1c2834; border: 1px solid #f5a623; color: #fff; }
.sc-cc-btn-gl:hover { background: #24364a; }
.sc-cc-btn-dr { background: transparent; border: 1px solid #3a4a5c; color: #e8edf2; min-height: 44px; }
.sc-cc-btn-dr:hover { border-color: #9aa7b4; }
.sc-cc-btn:focus-visible, .sc-cc-x:focus-visible, .sc-cc-sw:focus-visible, .sc-cc a:focus-visible, .sc-cc-ust a:focus-visible {
  outline: 2px solid #f5a623; outline-offset: 2px;
}

/* 2. poziom: telefon - ten sam arkusz rozciągnięty do góry */
.sc-cc-ust {
  position: fixed; left: 0; right: 0; top: 92px; bottom: 0; z-index: 1042;
  background: #111a24; color: #e8edf2;
  border-top: 2px solid #f5a623; border-radius: 16px 16px 0 0;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, .35);
  padding: 18px 16px; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
  outline: none;
}
.sc-cc-tlo { position: fixed; inset: 0; z-index: 1041; background: rgba(5, 10, 16, .6); }
.sc-cc-ust-glowa { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.sc-cc-ust-tytul { font-size: 17px; font-weight: 600; line-height: 1.3; }
.sc-cc-x {
  flex: 0 0 auto; width: 44px; height: 44px; margin: -8px -8px -8px 0; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent; border: 0; border-radius: 8px; color: #9aa7b4; cursor: pointer;
}
.sc-cc-x:hover { color: #e8edf2; }
.sc-cc-intro { margin: 0 0 12px; font-size: 13.5px; line-height: 1.5; color: #c5cfd9; }
.sc-cc-kat { list-style: none; margin: 0; padding: 0; }
.sc-cc-kat li {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 0; border-top: 1px solid #22303e; margin: 0;
}
.sc-cc-kat li:last-child { border-bottom: 1px solid #22303e; }
.sc-cc-kat-txt { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.sc-cc-kat-naz { font-size: 15px; font-weight: 600; color: #e8edf2; }
.sc-cc-kat-opis { font-size: 13px; line-height: 1.45; color: #c5cfd9; }
.sc-cc-zawsze { flex: 0 0 auto; font-size: 13px; font-weight: 600; color: #7fd1a8; text-align: right; }

/* przełącznik 48x28, cel dotyku 52x44 */
.sc-cc-sw {
  flex: 0 0 auto; width: 52px; height: 44px; padding: 0; margin: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent; border: 0; border-radius: 16px; cursor: pointer;
}
.sc-cc-sw-tor {
  position: relative; display: block; width: 48px; height: 28px; border-radius: 14px;
  background: #2a3846; border: 1px solid #3a4a5c; transition: background .15s, border-color .15s;
}
.sc-cc-sw-tor::after {
  content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%;
  background: #9aa7b4; transition: transform .15s, background .15s;
}
.sc-cc-sw[aria-checked="true"] .sc-cc-sw-tor { background: #f5a623; border-color: #f5a623; }
.sc-cc-sw[aria-checked="true"] .sc-cc-sw-tor::after { transform: translateX(20px); background: #111a24; }

.sc-cc-admin { margin: 12px 0 0; font-size: 12px; line-height: 1.5; color: #9aa7b4; }
.sc-cc-przyciski2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.sc-cc-przyciski2 .sc-cc-btn-dr { grid-column: 1 / -1; }

/* stopka: link Ustawienia cookies */
.footer-col ul li a.sc-cc-stopka, a.sc-cc-stopka { color: #f5a623; display: inline-flex; align-items: center; gap: 6px; }
a.sc-cc-stopka:hover { color: #ffbf4d; }

/* nad dolnym paskiem nawigacji (#mobile-bottom-nav, 58 px przy <= 768 px) */
@media (max-width: 768px) {
  .sc-cc, .sc-cc-ust { bottom: 58px; }
}

@media (prefers-reduced-motion: reduce) {
  .sc-cc-sw-tor, .sc-cc-sw-tor::after { transition: none; }
}

/* komputer */
@media (min-width: 1024px) {
  .sc-cc { border-radius: 0; padding: 16px 24px; }
  .sc-cc-wn { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; gap: 24px; }
  .sc-cc-tresc { flex: 1 1 auto; min-width: 0; }
  .sc-cc-tresc p:last-child { margin-bottom: 0; }
  .sc-cc-przyciski { display: flex; flex: 0 0 auto; align-items: center; gap: 10px; margin-top: 0; }
  .sc-cc-przyciski .sc-cc-btn-gl { width: 140px; }
  .sc-cc-btn-ust { order: -1; padding: 6px 18px; }

  .sc-cc-ust {
    top: 50%; left: 50%; right: auto; bottom: auto; width: 560px; max-width: calc(100vw - 32px); max-height: calc(100vh - 48px);
    transform: translate(-50%, -50%); border-radius: 16px; border-top: 2px solid #f5a623; padding: 22px 24px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, .5);
  }
  .sc-cc-przyciski2 { grid-template-columns: 1fr 1fr 1fr; }
  .sc-cc-przyciski2 .sc-cc-btn-dr { grid-column: auto; min-height: 48px; }
}
