/* Cookie Consent Styles — Abbey Total Care Group */
:root {
  --cookie-bg: rgba(255, 255, 255, 0.98);
  --cookie-text: var(--acc-ink-900, #151b26);
  --cookie-shadow: 0 20px 60px rgba(12, 43, 45, 0.25);
  --cookie-border: rgba(12, 43, 45, 0.08);
}

.cookie-consent-banner {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 100%;
  max-width: 420px;
  background: var(--cookie-bg);
  border: 1px solid var(--cookie-border);
  border-radius: var(--acc-radius-lg, 1.6rem);
  box-shadow: var(--cookie-shadow);
  padding: 28px;
  z-index: 9999;
  display: none; /* Controlled by JS */
  flex-direction: column;
  gap: 20px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  animation: cookieFadeIn 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes cookieFadeIn {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.cookie-consent-banner.hiding {
  animation: cookieFadeOut 0.4s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes cookieFadeOut {
  to {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
}

.cookie-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cookie-header i {
  font-size: 24px;
  color: var(--acc-gold-500, #c99a4a);
}

.cookie-header h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
  font-family: 'Fraunces', serif;
}

.cookie-body p {
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--acc-ink-700, #2d3748);
  margin: 0;
}

.cookie-body a {
  color: var(--acc-brand-700, #1b4d52);
  text-decoration: underline;
  font-weight: 600;
}

.cookie-footer {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cookie-btns-main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.cookie-btn {
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cookie-btn-accept {
  background: var(--acc-gold-500, #c99a4a);
  color: #fff;
}

.cookie-btn-accept:hover {
  background: var(--acc-gold-600, #ae833a);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(201, 154, 74, 0.3);
}

.cookie-btn-reject {
  background: transparent;
  border: 1.5px solid var(--acc-brand-700, #1b4d52);
  color: var(--acc-brand-700, #1b4d52);
}

.cookie-btn-reject:hover {
  background: rgba(12, 43, 45, 0.05);
  transform: translateY(-2px);
}

.cookie-btn-settings {
  background: transparent;
  color: var(--acc-ink-500, #5a6475);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  width: fit-content;
  margin: 0 auto;
}

.cookie-btn-settings:hover {
  color: var(--acc-brand-900, #0c2b2d);
  text-decoration: underline;
}

/* Modal Styles */
.cookie-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(12, 43, 45, 0.4);
  backdrop-filter: blur(10px);
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.cookie-modal {
  background: #fff;
  width: 100%;
  max-width: 540px;
  border-radius: var(--acc-radius-lg, 1.6rem);
  padding: 40px;
  position: relative;
  box-shadow: var(--cookie-shadow);
  max-height: 90vh;
  overflow-y: auto;
}

.cookie-modal-header {
  margin-bottom: 24px;
}

.cookie-modal-header h2 {
  font-family: 'Fraunces', serif;
  font-size: 1.75rem;
  color: var(--acc-brand-900, #0c2b2d);
  margin-bottom: 8px;
}

.cookie-modal-close {
  position: absolute;
  top: 24px;
  right: 24px;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--acc-ink-400, #738099);
  transition: color 0.3s ease;
}

.cookie-modal-close:hover {
  color: var(--acc-ink-900, #151b26);
}

.cookie-pref-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 32px;
}

.cookie-pref-item {
  display: flex;
  gap: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--acc-border, #dce4ea);
}

.cookie-pref-info {
  flex: 1;
}

.cookie-pref-info h4 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--acc-brand-900, #0c2b2d);
}

.cookie-pref-info p {
  font-size: 0.88rem;
  color: var(--acc-ink-500, #5a6475);
  margin: 0;
  line-height: 1.5;
}

/* Switch Styles */
.cookie-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 24px;
  flex-shrink: 0;
}

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

.cookie-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #e2e8f0;
  transition: .4s;
  border-radius: 24px;
}

.cookie-slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

input:checked + .cookie-slider {
  background-color: var(--acc-brand-700, #1b4d52);
}

input:focus + .cookie-slider {
  box-shadow: 0 0 1px var(--acc-brand-700, #1b4d52);
}

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

input:disabled + .cookie-slider {
  opacity: 0.6;
  cursor: not-allowed;
}

.cookie-modal-footer {
  display: flex;
  gap: 16px;
}

@media (max-width: 576px) {
  .cookie-consent-banner {
    bottom: 0;
    right: 0;
    left: 0;
    max-width: none;
    border-radius: 20px 20px 0 0;
    padding: 24px;
  }
  
  .cookie-modal {
    padding: 24px;
  }
  
  .cookie-modal-footer {
    flex-direction: column;
  }
}
