/* Cookie Consent Banner — Eaves & Decor
   Floating card, bottom-right corner, GDPR-compliant */

.ead-cookie-overlay {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 99999;
  max-width: 420px;
  width: calc(100% - 40px);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: #fff;
  opacity: 0;
  transform: translateY(30px);
  animation: ead-slide-in 0.5s ease-out 1s forwards;
}

@keyframes ead-slide-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.ead-cookie-card {
  background: #1a1a2e;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  padding: 24px;
  overflow: hidden;
}

.ead-cookie-card h2 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 600;
  color: #fff;
}

.ead-cookie-card p {
  margin: 0 0 16px;
  font-size: 13px;
  color: #ccc;
}

/* Toggle section (expandable) */
.ead-cookie-toggles {
  display: none;
  margin-bottom: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 12px;
}

.ead-cookie-toggles.ead-open {
  display: block;
}

.ead-cookie-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
}

.ead-cookie-toggle-label {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding-right: 12px;
}

.ead-cookie-toggle-name {
  font-size: 14px;
  font-weight: 500;
  color: #fff;
}

.ead-cookie-toggle-desc {
  font-size: 12px;
  color: #999;
  margin-top: 2px;
}

/* Toggle switch */
.ead-cookie-switch {
  position: relative;
  width: 44px;
  min-width: 44px;
  height: 24px;
}

.ead-cookie-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.ead-cookie-switch .ead-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #444;
  border-radius: 24px;
  transition: background 0.2s;
}

.ead-cookie-switch .ead-slider::before {
  content: "";
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.2s;
}

.ead-cookie-switch input:checked + .ead-slider {
  background: #3b5bdb;
}

.ead-cookie-switch input:checked + .ead-slider::before {
  transform: translateX(20px);
}

.ead-cookie-switch input:disabled + .ead-slider {
  background: #3b5bdb;
  opacity: 0.6;
  cursor: not-allowed;
}

.ead-cookie-switch input:disabled + .ead-slider::before {
  transform: translateX(20px);
}

/* Focus states */
.ead-cookie-switch input:focus-visible + .ead-slider {
  outline: 2px solid #7b9ef5;
  outline-offset: 2px;
}

.ead-cookie-card button:focus-visible,
.ead-cookie-card .ead-manage-link:focus-visible {
  outline: 2px solid #7b9ef5;
  outline-offset: 2px;
}

/* Always-on badge */
.ead-always-on {
  font-size: 11px;
  color: #7b9ef5;
  font-weight: 500;
  white-space: nowrap;
}

/* Buttons */
.ead-cookie-buttons {
  display: flex;
  gap: 10px;
  margin-bottom: 8px;
}

.ead-btn-accept {
  flex: 1;
  padding: 10px 16px;
  background: #3b5bdb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  font-family: inherit;
}

.ead-btn-accept:hover {
  background: #2f4cc5;
}

.ead-btn-save {
  flex: 1;
  padding: 10px 16px;
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  font-family: inherit;
}

.ead-btn-save:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

/* Manage preferences link */
.ead-manage-link {
  display: inline-block;
  background: none;
  border: none;
  color: #7b9ef5;
  font-size: 12px;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-family: inherit;
}

.ead-manage-link:hover {
  color: #9db8ff;
}

/* Mobile adjustments */
@media (max-width: 480px) {
  .ead-cookie-overlay {
    bottom: 10px;
    right: 10px;
    width: calc(100% - 20px);
    max-width: none;
  }

  .ead-cookie-card {
    padding: 18px;
  }

  .ead-cookie-buttons {
    flex-direction: column;
  }
}
