.f5-cookie-banner,
.f5-cookie-modal-backdrop {
  font-family: inherit;
}

.f5-cookie-banner[hidden],
.f5-cookie-modal-backdrop[hidden] {
  display: none !important;
}

.f5-cookie-banner {
  position: fixed;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 80;
  max-width: 1120px;
  margin: 0 auto;
  color: #f8fafc;
  background: rgba(15, 47, 58, 0.97);
  border: 1px solid rgba(0, 255, 170, 0.24);
  border-radius: 18px;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(16px);
}

.f5-cookie-banner__content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  padding: 20px;
}

.f5-cookie-banner__title {
  margin: 0 0 6px;
  color: #f8fafc;
  font-size: 1rem;
  font-weight: 800;
}

.f5-cookie-banner__text {
  margin: 0;
  color: #cbd5e1;
  font-size: 0.92rem;
  line-height: 1.55;
}

.f5-cookie-banner__text a,
.f5-cookie-legal a {
  color: #00ffaa;
  font-weight: 800;
}

.f5-cookie-banner__actions,
.f5-cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.f5-cookie-btn {
  min-height: 42px;
  border: 1px solid rgba(203, 213, 225, 0.28);
  border-radius: 999px;
  padding: 10px 16px;
  cursor: pointer;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 800;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.08);
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.f5-cookie-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(0, 255, 170, 0.46);
}

.f5-cookie-btn:focus-visible,
.f5-cookie-footer-link:focus-visible,
.f5-cookie-toggle input:focus-visible + .f5-cookie-toggle__track {
  outline: 3px solid rgba(0, 255, 170, 0.45);
  outline-offset: 3px;
}

.f5-cookie-btn--primary {
  border-color: #00ffaa;
  color: #0f2f3a;
  background: #00ffaa;
}

.f5-cookie-btn--secondary {
  border-color: rgba(248, 250, 252, 0.5);
  color: #f8fafc;
  background: rgba(248, 250, 252, 0.12);
}

.f5-cookie-btn--ghost {
  border-color: transparent;
  color: #cbd5e1;
  background: transparent;
}

.f5-cookie-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(2, 10, 14, 0.68);
}

.f5-cookie-modal {
  width: min(640px, 100%);
  max-height: min(760px, calc(100vh - 40px));
  overflow: auto;
  color: #f8fafc;
  background: #0f2f3a;
  border: 1px solid rgba(0, 255, 170, 0.24);
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
}

.f5-cookie-modal__inner {
  padding: 26px;
}

.f5-cookie-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.f5-cookie-modal__title {
  margin: 0;
  color: #f8fafc;
  font-size: 1.35rem;
  line-height: 1.2;
}

.f5-cookie-modal__intro {
  margin: 0 0 20px;
  color: #cbd5e1;
  font-size: 0.94rem;
  line-height: 1.6;
}

.f5-cookie-close {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(203, 213, 225, 0.22);
  border-radius: 999px;
  cursor: pointer;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.06);
  font-size: 1.3rem;
  line-height: 1;
}

.f5-cookie-category {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-top: 1px solid rgba(203, 213, 225, 0.14);
}

.f5-cookie-category__name {
  margin: 0 0 4px;
  color: #f8fafc;
  font-size: 0.98rem;
  font-weight: 800;
}

.f5-cookie-category__desc {
  margin: 0;
  color: #cbd5e1;
  font-size: 0.88rem;
  line-height: 1.55;
}

.f5-cookie-status {
  display: inline-flex;
  margin-top: 8px;
  color: #00ffaa;
  font-size: 0.78rem;
  font-weight: 800;
}

.f5-cookie-toggle {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.f5-cookie-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.f5-cookie-toggle__track {
  position: relative;
  width: 52px;
  height: 30px;
  border: 1px solid rgba(203, 213, 225, 0.26);
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.22);
  transition: background 0.15s ease, border-color 0.15s ease;
}

.f5-cookie-toggle__track::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: #f8fafc;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  transition: transform 0.15s ease;
}

.f5-cookie-toggle input:checked + .f5-cookie-toggle__track {
  border-color: rgba(0, 255, 170, 0.7);
  background: rgba(0, 255, 170, 0.36);
}

.f5-cookie-toggle input:checked + .f5-cookie-toggle__track::after {
  transform: translateX(22px);
}

.f5-cookie-toggle input:disabled + .f5-cookie-toggle__track {
  cursor: not-allowed;
  opacity: 0.85;
}

.f5-cookie-legal {
  margin: 18px 0 0;
  color: #cbd5e1;
  font-size: 0.78rem;
  line-height: 1.55;
}

.f5-cookie-actions {
  margin-top: 22px;
}

.footer-links .f5-cookie-footer-link {
  display: inline-flex;
  padding: 0;
  border: 0;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.5);
  background: transparent;
  font: inherit;
  font-size: 0.875rem;
  font-weight: 700;
  text-align: left;
}

.footer-links .f5-cookie-footer-link:hover {
  color: #fff;
}

@media (max-width: 820px) {
  .f5-cookie-banner {
    left: 12px;
    right: 12px;
    bottom: 12px;
    border-radius: 16px;
  }

  .f5-cookie-banner__content {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 18px;
  }

  .f5-cookie-banner__actions,
  .f5-cookie-actions {
    justify-content: stretch;
  }

  .f5-cookie-btn {
    flex: 1 1 100%;
  }
}

@media (max-width: 560px) {
  .f5-cookie-modal-backdrop {
    align-items: end;
    padding: 10px;
  }

  .f5-cookie-modal {
    max-height: calc(100vh - 20px);
    border-radius: 16px;
  }

  .f5-cookie-modal__inner {
    padding: 20px;
  }

  .f5-cookie-category {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}
