/* =============================================
   SHOP'N MAX — BANDEAU COOKIES RGPD
============================================= */

/* ===== BANDEAU BAS DE PAGE ===== */
#cookie-banner {
  position: fixed;
  bottom: -200px;
  left: 0; right: 0;
  background: var(--brown-deep);
  z-index: 9998;
  transition: bottom .4s cubic-bezier(.4,0,.2,1);
  box-shadow: 0 -4px 24px rgba(0,0,0,.3);
}
#cookie-banner.show { bottom: 0; }

.cookie-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.cookie-text {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  flex: 1;
  min-width: 280px;
}

.cookie-icon { font-size: 1.8rem; flex-shrink: 0; margin-top: 2px; }

.cookie-text strong {
  display: block;
  color: white;
  font-size: .95rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.cookie-text p {
  color: rgba(212,184,150,.7);
  font-size: .78rem;
  line-height: 1.6;
  margin: 0;
}

.cookie-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-shrink: 0;
  flex-wrap: wrap;
}

.cookie-btn {
  padding: 10px 20px;
  border-radius: 50px;
  font-size: .8rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  font-family: 'Montserrat', sans-serif;
  transition: all .3s ease;
  white-space: nowrap;
  letter-spacing: .04em;
}

.cookie-settings-btn {
  background: transparent;
  color: var(--brown-pale);
  border: 1px solid rgba(212,184,150,.4);
}
.cookie-settings-btn:hover {
  border-color: var(--brown-pale);
  color: white;
}

.cookie-refuse {
  background: transparent;
  color: var(--brown-pale);
  border: 1px solid rgba(212,184,150,.4);
}
.cookie-refuse:hover {
  background: rgba(212,184,150,.1);
  color: white;
}

.cookie-accept {
  background: var(--orange);
  color: white;
  box-shadow: 0 4px 14px rgba(196,84,10,.4);
}
.cookie-accept:hover {
  background: var(--orange-dark);
  transform: translateY(-1px);
}

/* ===== PANNEAU PERSONNALISATION ===== */
#cookie-settings {
  position: fixed;
  bottom: -100%;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 560px;
  background: white;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  z-index: 9999;
  box-shadow: 0 -8px 40px rgba(0,0,0,.25);
  transition: bottom .4s cubic-bezier(.4,0,.2,1);
  max-height: 90vh;
  overflow-y: auto;
}
#cookie-settings.show { bottom: 0; }

.cookie-settings-inner { padding: 32px 28px 28px; position: relative; }

.cookie-close {
  position: absolute;
  top: 16px; right: 16px;
  background: var(--cream);
  border: none;
  width: 32px; height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  color: var(--text-light);
  transition: all .3s ease;
}
.cookie-close:hover { background: var(--border); color: var(--brown-dark); }

.cookie-settings-inner h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  color: var(--brown-dark);
  margin-bottom: 10px;
}

.cookie-settings-inner > p {
  font-size: .85rem;
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 24px;
}

/* Options cookies */
.cookie-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  gap: 16px;
}
.cookie-option:last-of-type { border-bottom: none; }

.cookie-option-info { flex: 1; }
.cookie-option-info strong {
  display: block;
  font-size: .9rem;
  color: var(--brown-dark);
  font-weight: 700;
  margin-bottom: 3px;
}
.cookie-option-info span {
  font-size: .78rem;
  color: var(--text-light);
  line-height: 1.5;
}

.toggle-always {
  font-size: .72rem;
  font-weight: 700;
  color: #27ae60;
  white-space: nowrap;
}

/* Toggle switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--border);
  border-radius: 26px;
  cursor: pointer;
  transition: .3s;
}
.toggle-slider::before {
  content: '';
  position: absolute;
  width: 20px; height: 20px;
  left: 3px; top: 3px;
  background: white;
  border-radius: 50%;
  transition: .3s;
  box-shadow: 0 1px 4px rgba(0,0,0,.2);
}
.toggle-switch input:checked + .toggle-slider { background: var(--orange); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(22px); }

.cookie-settings-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
  justify-content: flex-end;
}

.cookie-legal {
  font-size: .75rem;
  color: var(--text-light);
  text-align: center;
  margin-top: 14px;
}
.cookie-legal a {
  color: var(--orange);
  font-weight: 600;
  text-decoration: none;
}
.cookie-legal a:hover { text-decoration: underline; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .cookie-inner { flex-direction: column; gap: 16px; padding: 16px; }
  .cookie-actions { width: 100%; justify-content: stretch; }
  .cookie-btn { flex: 1; text-align: center; }
  #cookie-settings { width: 100%; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
  .cookie-settings-inner { padding: 24px 20px 20px; }
  .cookie-settings-actions { flex-direction: column; }
}