/* Pyxios Cookie Consent */
.pyxcc {
  --pyxcc-accent: #1d1d1f;
  --pyxcc-on-accent: #fff;
  --pyxcc-bg: rgba(255, 255, 255, .9);
  --pyxcc-fg: #1d1d1f;
  --pyxcc-muted: #6b6b70;
  --pyxcc-line: rgba(0, 0, 0, .08);
  --pyxcc-radius: 20px;
  --pyxcc-ease: cubic-bezier(.16, 1.2, .3, 1);

  position: fixed;
  z-index: 2147483000;
  bottom: 20px;
  left: 20px;
  width: calc(100% - 40px);
  max-width: 420px;
  color: var(--pyxcc-fg);
  font-family: inherit;
  font-size: 14px;
  line-height: 1.5;
  text-align: left;
  opacity: 0;
  transform: translateY(calc(100% + 40px)) scale(.96);
  transition: transform .7s var(--pyxcc-ease), opacity .4s ease;
  pointer-events: none;
}
.pyxcc[hidden] { display: none !important; }
.pyxcc *, .pyxcc *::before, .pyxcc *::after { box-sizing: border-box; }

.pyxcc.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.pyxcc.is-leaving {
  opacity: 0;
  transform: translateY(24px) scale(.97);
  transition: transform .4s cubic-bezier(.4, 0, 1, 1), opacity .3s ease;
}

.pyxcc--card-right { left: auto; right: 20px; }
.pyxcc--bar { left: 20px; right: 20px; width: auto; max-width: 1180px; margin: 0 auto; }

/* Card */
.pyxcc__inner {
  display: flex;
  gap: 16px;
  padding: 22px;
  background: var(--pyxcc-bg);
  -webkit-backdrop-filter: blur(18px) saturate(1.6);
  backdrop-filter: blur(18px) saturate(1.6);
  border: 1px solid var(--pyxcc-line);
  border-radius: var(--pyxcc-radius);
  box-shadow: 0 24px 60px -16px rgba(0, 0, 0, .28), 0 2px 8px rgba(0, 0, 0, .06);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .pyxcc { --pyxcc-bg: #fff; }
}

.pyxcc__icon {
  flex: 0 0 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: var(--pyxcc-accent);
  color: var(--pyxcc-on-accent);
  transform-origin: 50% 60%;
}
.pyxcc.is-visible .pyxcc__icon { animation: pyxcc-wobble 1.1s .35s var(--pyxcc-ease) both; }

.pyxcc__body { flex: 1 1 auto; min-width: 0; }
.pyxcc__title { margin: 0 0 4px; font-size: 16px; font-weight: 700; letter-spacing: -.01em; color: inherit; }
.pyxcc__msg { margin: 0; color: var(--pyxcc-muted); }
.pyxcc__link { color: var(--pyxcc-fg); text-decoration: underline; text-underline-offset: 2px; white-space: nowrap; }
.pyxcc__link:hover { color: var(--pyxcc-accent); }

/* Staggered content entrance */
.pyxcc.is-visible .pyxcc__title,
.pyxcc.is-visible .pyxcc__msg,
.pyxcc.is-visible .pyxcc__actions { animation: pyxcc-rise .6s var(--pyxcc-ease) both; }
.pyxcc.is-visible .pyxcc__title { animation-delay: .12s; }
.pyxcc.is-visible .pyxcc__msg { animation-delay: .18s; }
.pyxcc.is-visible .pyxcc__actions { animation-delay: .26s; }

/* Preferences */
.pyxcc__prefs { margin-top: 14px; display: grid; gap: 8px; }
.pyxcc__prefs:not([hidden]) { animation: pyxcc-expand .45s var(--pyxcc-ease) both; }
.pyxcc__prefs[hidden] { display: none; }

.pyxcc__cat {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid var(--pyxcc-line);
  border-radius: 12px;
  background: rgba(255, 255, 255, .6);
  cursor: pointer;
  font-weight: 400;
  transition: border-color .2s, background .2s;
}
.pyxcc__cat:hover { border-color: rgba(0, 0, 0, .16); }
.pyxcc__cat.is-locked { cursor: default; }
.pyxcc__cat-text { flex: 1 1 auto; min-width: 0; }
.pyxcc__cat-text strong { display: block; font-size: 13.5px; color: var(--pyxcc-fg); }
.pyxcc__cat-text small { display: block; font-size: 12px; line-height: 1.4; color: var(--pyxcc-muted); }

.pyxcc__switch { position: relative; flex: 0 0 40px; width: 40px; height: 24px; }
.pyxcc__switch input {
  position: absolute; inset: 0; width: 100%; height: 100%; margin: 0;
  opacity: 0; cursor: inherit; z-index: 1;
}
.pyxcc__switch i {
  position: absolute; inset: 0; border-radius: 999px; background: #d4d4d8;
  transition: background .25s ease;
}
.pyxcc__switch i::after {
  content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px;
  border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
  transition: transform .35s var(--pyxcc-ease);
}
.pyxcc__switch input:checked + i { background: var(--pyxcc-accent); }
.pyxcc__switch input:checked + i::after { transform: translateX(16px); }
.pyxcc__switch input:disabled + i { opacity: .55; }
.pyxcc__switch input:focus-visible + i { outline: 2px solid var(--pyxcc-accent); outline-offset: 2px; }

/* Buttons */
.pyxcc__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; }
.pyxcc__btn {
  appearance: none;
  margin: 0;
  padding: 10px 16px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  text-transform: none;
  letter-spacing: 0;
  transition: transform .2s var(--pyxcc-ease), background .2s, border-color .2s, box-shadow .2s, color .2s;
}
.pyxcc__btn[hidden] { display: none; }
.pyxcc__btn:active { transform: scale(.96); }
.pyxcc__btn:focus-visible { outline: 2px solid var(--pyxcc-accent); outline-offset: 2px; }

.pyxcc__btn--primary {
  margin-left: auto;
  background: var(--pyxcc-accent);
  color: var(--pyxcc-on-accent);
  box-shadow: 0 6px 16px -6px var(--pyxcc-accent);
}
.pyxcc__btn--primary:hover { transform: translateY(-1px); box-shadow: 0 10px 22px -8px var(--pyxcc-accent); }
.pyxcc__btn--ghost { background: transparent; color: var(--pyxcc-fg); border-color: rgba(0, 0, 0, .15); }
.pyxcc__btn--ghost:hover { border-color: var(--pyxcc-fg); }
.pyxcc__btn--text {
  padding-left: 4px; padding-right: 4px;
  background: none; color: var(--pyxcc-muted);
  text-decoration: underline; text-underline-offset: 3px;
}
.pyxcc__btn--text:hover { color: var(--pyxcc-fg); }

/* Bar layout on desktop */
@media (min-width: 900px) {
  .pyxcc--bar .pyxcc__inner { align-items: center; padding: 18px 22px; }
  .pyxcc--bar .pyxcc__body { display: grid; grid-template-columns: 1fr auto; column-gap: 24px; align-items: center; }
  .pyxcc--bar .pyxcc__title, .pyxcc--bar .pyxcc__msg { grid-column: 1; }
  .pyxcc--bar .pyxcc__actions { grid-column: 2; grid-row: 1 / span 2; margin-top: 0; flex-wrap: nowrap; }
  .pyxcc--bar .pyxcc__prefs { grid-column: 1 / -1; grid-template-columns: repeat(3, 1fr); }
  .pyxcc--bar.is-expanded .pyxcc__actions { grid-row: auto; grid-column: 1 / -1; margin-top: 14px; }
}

/* Mobile: bottom sheet */
@media (max-width: 575px) {
  .pyxcc, .pyxcc--card-right, .pyxcc--bar { left: 0; right: 0; bottom: 0; width: 100%; max-width: none; }
  .pyxcc__inner {
    flex-direction: column; gap: 12px; padding: 20px 18px calc(18px + env(safe-area-inset-bottom));
    border-radius: 22px 22px 0 0; border-bottom: 0;
  }
  .pyxcc__icon { flex-basis: auto; width: 40px; height: 40px; }
  .pyxcc__actions { display: grid; grid-template-columns: 1fr 1fr; }
  .pyxcc__btn--primary { grid-column: 1 / -1; grid-row: 1; margin-left: 0; padding: 13px 16px; }
  .pyxcc__btn--text { grid-column: 1 / -1; justify-self: center; }
  .pyxcc.is-expanded .pyxcc__prefs { max-height: 46vh; overflow-y: auto; }
}

/* Reopen button */
.pyxcc-reopen {
  --pyxcc-accent: #1d1d1f;
  --pyxcc-on-accent: #fff;
  position: fixed;
  z-index: 2147482999;
  left: 16px;
  bottom: 16px;
  width: 42px;
  height: 42px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: var(--pyxcc-accent);
  color: var(--pyxcc-on-accent);
  box-shadow: 0 8px 20px -6px rgba(0, 0, 0, .35);
  cursor: pointer;
  opacity: 0;
  transform: scale(.4) rotate(-90deg);
  transition: transform .5s cubic-bezier(.16, 1.2, .3, 1), opacity .3s ease;
}
.pyxcc-reopen[hidden] { display: none; }
.pyxcc-reopen.is-visible { opacity: .85; transform: none; }
.pyxcc-reopen.is-visible:hover { opacity: 1; transform: scale(1.08) rotate(12deg); }
.pyxcc-reopen:focus-visible { outline: 2px solid var(--pyxcc-accent); outline-offset: 3px; }

/* Keyframes */
@keyframes pyxcc-rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes pyxcc-expand { from { opacity: 0; transform: translateY(-6px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes pyxcc-wobble {
  0% { transform: scale(.5) rotate(-40deg); }
  55% { transform: scale(1.1) rotate(10deg); }
  75% { transform: scale(.97) rotate(-5deg); }
  100% { transform: scale(1) rotate(0); }
}

@media (prefers-reduced-motion: reduce) {
  .pyxcc, .pyxcc *, .pyxcc-reopen { animation: none !important; transition: opacity .2s linear !important; }
  .pyxcc, .pyxcc.is-leaving { transform: none !important; }
}
