/* Cookie consent – upravte barvy/fonty podle webu */
:root {
  --cc-bg: #ffffff;
  --cc-text: #1f2328;
  --cc-muted: #5b636b;
  --cc-primary: #1f2328;
  --cc-primary-text: #ffffff;
  --cc-border: #d0d7de;
  --cc-accent: #2e7d32;
  --cc-radius: 8px;
}

.cc-bar[hidden], .cc-modal[hidden] { display: none !important; }

/* ---------- Lišta ---------- */
.cc-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 99999;
  background: var(--cc-bg); color: var(--cc-text);
  box-shadow: 0 -4px 20px rgba(0,0,0,.12);
  font-size: 14px; line-height: 1.5;
}
.cc-bar__inner {
  max-width: 1200px; margin: 0 auto; padding: 18px 20px;
  display: flex; align-items: center; gap: 24px;
}
.cc-bar__text { flex: 1; }
.cc-bar__title { display: block; font-size: 16px; margin-bottom: 4px; }
.cc-bar__text p { margin: 0; color: var(--cc-muted); }
.cc-bar a, .cc-modal a { color: inherit; text-decoration: underline; }
.cc-bar__buttons { display: flex; gap: 8px; flex-shrink: 0; }

/* ---------- Tlačítka ---------- */
.cc-btn {
  font: inherit; font-weight: 600; cursor: pointer;
  padding: 10px 18px; border-radius: var(--cc-radius);
  border: 1px solid var(--cc-primary); white-space: nowrap;
}
.cc-btn--primary { background: var(--cc-primary); color: var(--cc-primary-text); }
.cc-btn--outline { background: transparent; color: var(--cc-primary); }
.cc-btn:hover { opacity: .85; }
.cc-btn:focus-visible, .cc-modal__close:focus-visible { outline: 2px solid var(--cc-accent); outline-offset: 2px; }

/* ---------- Modál ---------- */
.cc-modal {
  position: fixed; inset: 0; z-index: 100000;
  background: rgba(0,0,0,.5);
  display: flex; align-items: center; justify-content: center; padding: 16px;
}
.cc-modal__box {
  position: relative; background: var(--cc-bg); color: var(--cc-text);
  width: 100%; max-width: 600px; max-height: 90vh; overflow-y: auto;
  border-radius: 12px; padding: 28px; font-size: 14px; line-height: 1.5;
}
.cc-modal__box:focus { outline: none; }
.cc-modal__title { margin: 0 0 8px; font-size: 20px; }
.cc-modal__intro { margin: 0 0 16px; color: var(--cc-muted); }
.cc-modal__close {
  position: absolute; top: 12px; right: 14px;
  background: none; border: 0; font-size: 28px; line-height: 1; cursor: pointer; color: var(--cc-muted);
}
.cc-modal__buttons { display: flex; gap: 8px; justify-content: flex-end; margin-top: 20px; flex-wrap: wrap; }

.cc-cat { border-top: 1px solid var(--cc-border); padding: 14px 0; }
.cc-cat__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; }
.cc-cat p { margin: 6px 0 0; color: var(--cc-muted); }
.cc-cat__always { font-size: 13px; font-weight: 600; color: var(--cc-accent); }

/* Přepínač */
.cc-switch { position: relative; width: 44px; height: 24px; flex-shrink: 0; }
.cc-switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.cc-switch__slider {
  position: absolute; inset: 0; background: #c4c9cf; border-radius: 24px; transition: background .2s; pointer-events: none;
}
.cc-switch__slider::before {
  content: ""; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px;
  background: #fff; border-radius: 50%; transition: transform .2s;
}
.cc-switch input:checked + .cc-switch__slider { background: var(--cc-accent); }
.cc-switch input:checked + .cc-switch__slider::before { transform: translateX(20px); }
.cc-switch input:focus-visible + .cc-switch__slider { outline: 2px solid var(--cc-accent); outline-offset: 2px; }

/* ---------- Mobil ---------- */
@media (max-width: 768px) {
  .cc-bar__inner { flex-direction: column; align-items: stretch; gap: 14px; }
  .cc-bar__buttons { flex-direction: column-reverse; }
  .cc-btn { width: 100%; }
  .cc-modal__buttons { flex-direction: column-reverse; }
  .cc-modal__box { padding: 22px 18px; }
}
