.cookie-banner {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  width: min(980px, calc(100% - 20px));
  border: 1px solid #6e4a2a;
  border-radius: 20px;
  background: linear-gradient(110deg, rgba(33, 14, 7, 0.97), rgba(45, 19, 10, 0.94) 62%, rgba(37, 14, 8, 0.96));
  color: #ead2b3;
  box-shadow: 0 18px 34px rgba(20, 9, 4, 0.5);
  padding: 16px 18px;
  z-index: 1000;
  backdrop-filter: blur(3px);
}

.cookie-banner__top {
  display: grid;
  gap: 12px;
}

.cookie-banner__text {
  margin: 0;
  font-size: clamp(0.98rem, 2vw, 1.02rem);
  line-height: 1.45;
}

.cookie-banner__text a {
  color: #f1d9b8;
  text-decoration: underline;
  text-underline-offset: 3px;
  margin-left: 8px;
}

.cookie-banner__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.cookie-banner__btn {
  border: 1px solid #9b6a3a;
  background: rgba(140, 88, 41, 0.24);
  color: #f2ddc3;
  border-radius: 999px;
  padding: 8px 16px;
  font: inherit;
  letter-spacing: 0.02em;
  cursor: pointer;
}

.cookie-banner__btn:hover {
  background: rgba(166, 107, 48, 0.36);
}

.cookie-banner__btn-ghost {
  background: transparent;
}

.cookie-banner__details {
  margin-top: 14px;
  border-top: 1px solid rgba(203, 151, 105, 0.35);
  padding-top: 12px;
  display: grid;
  gap: 10px;
}

.cookie-banner__details[hidden] {
  display: none;
}

.cookie-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

.cookie-row__title {
  margin: 0;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.cookie-row__desc {
  margin: 2px 0 0;
  color: #d8bfa1;
}

.cookie-toggle {
  width: 60px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid #8c5f35;
  background: transparent;
  position: relative;
  cursor: pointer;
}

.cookie-toggle::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #e2be96;
  transition: transform 180ms ease;
}

.cookie-toggle.is-on::after {
  transform: translateX(26px);
}

.cookie-toggle.is-locked {
  opacity: 0.8;
  cursor: not-allowed;
}

.cookie-banner__details-actions {
  margin-top: 2px;
}

.legal-footer {
  border-top: 1px solid #ddd4c3;
  padding: 12px 16px 16px;
  color: #665b4d;
  font-size: 0.9rem;
  text-align: center;
}

.legal-footer a {
  color: inherit;
}

.legal-meta {
  margin: 0 0 4px;
}

.legal-madeby {
  margin: 0 0 6px;
  display: inline-flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.brolab-link {
  display: inline-flex;
  align-items: center;
}

.legal-logo {
  height: 20px;
  width: auto;
  display: block;
}

.social-overlay {
  position: fixed;
  inset: 0;
  background: rgba(24, 18, 14, 0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
  z-index: 900;
}

.social-fab {
  position: fixed;
  right: 16px;
  bottom: calc(16px + env(safe-area-inset-bottom));
  min-width: 86px;
  height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(86, 58, 32, 0.7);
  border-radius: 999px;
  background: rgba(245, 237, 224, 0.95);
  color: #4a3725;
  box-shadow: 0 8px 22px rgba(26, 15, 8, 0.24);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(2px);
  transition: transform 160ms ease, box-shadow 160ms ease, opacity 160ms ease;
  z-index: 930;
}

.social-fab:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(26, 15, 8, 0.28);
}

.social-fab__icon {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1;
}

.social-layer {
  position: fixed;
  right: 16px;
  bottom: calc(72px + env(safe-area-inset-bottom));
  width: min(220px, calc(100vw - 32px));
  border: 1px solid #d8cab0;
  border-radius: 15px;
  background: #fbf7ef;
  box-shadow: 0 12px 30px rgba(26, 15, 8, 0.2);
  padding: 8px;
  display: grid;
  gap: 6px;
  opacity: 0;
  transform: translateY(8px) scale(0.98);
  transform-origin: bottom right;
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
  z-index: 920;
}

.social-layer__link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 10px;
  border-radius: 10px;
  text-decoration: none;
  color: #3d2f22;
}

.social-layer__link:hover,
.social-layer__link:focus-visible {
  background: #efe4d1;
}

.social-layer__icon {
  min-width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #d9c3a1;
  color: #3f2f1d;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

body.social-open .social-overlay {
  opacity: 1;
  pointer-events: auto;
}

body.social-open .social-layer {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

body.social-open .social-fab__icon {
  transform: none;
}

body.has-cookie-banner .social-fab {
  bottom: calc(90px + env(safe-area-inset-bottom));
}

body.has-cookie-banner .social-layer {
  bottom: calc(146px + env(safe-area-inset-bottom));
}

@media (max-width: 700px) {
  .cookie-banner {
    padding: 12px;
    bottom: 10px;
    border-radius: 16px;
  }

  .cookie-banner__actions {
    justify-content: flex-start;
  }

  .cookie-row {
    grid-template-columns: 1fr;
  }

  .cookie-toggle {
    justify-self: end;
  }
}
