/* =====================================================
   COOKIE CONSENT BANNER – wadifatuk.com
   ===================================================== */

/* Banner */
.cookie-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: #0f172a;
  color: #cbd5e1;
  z-index: 99999;
  padding: 0;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.34,1.56,0.64,1);
  box-shadow: 0 -4px 30px rgba(0,0,0,0.3);
  border-top: 1px solid rgba(255,255,255,0.08);
}
.cookie-banner.show { transform: translateY(0); }

.cookie-banner-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.cookie-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.cookie-text { flex: 1; min-width: 220px; }
.cookie-text h3 {
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
}
.cookie-text p {
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.6;
  margin: 0;
}
.cookie-text a { color: #60a5fa; text-decoration: underline; }

.cookie-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  flex-shrink: 0;
}

.cookie-btn {
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  font-family: 'Tajawal', sans-serif;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  white-space: nowrap;
}
.cookie-btn-accept {
  background: linear-gradient(135deg, #1a56db, #4f46e5);
  color: #fff;
}
.cookie-btn-accept:hover { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(26,86,219,0.4); }
.cookie-btn-reject {
  background: rgba(255,255,255,0.08);
  color: #94a3b8;
  border: 1px solid rgba(255,255,255,0.12);
}
.cookie-btn-reject:hover { background: rgba(255,255,255,0.15); color: #fff; }
.cookie-btn-custom {
  background: none;
  color: #60a5fa;
  text-decoration: underline;
  padding: 10px 8px;
}

/* Customize Modal */
.cookie-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  z-index: 100000;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s;
}
.cookie-modal-overlay.open { opacity: 1; pointer-events: all; }
.cookie-modal {
  background: #fff;
  border-radius: 20px;
  padding: 32px;
  max-width: 500px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
}
.cookie-modal h2 { font-size: 20px; font-weight: 800; color: #0f172a; margin-bottom: 20px; }
.cookie-toggle-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid #e2e8f0;
}
.cookie-toggle-row:last-child { border-bottom: none; }
.cookie-toggle-info { flex: 1; }
.cookie-toggle-info h4 { font-size: 15px; font-weight: 700; color: #0f172a; margin-bottom: 4px; }
.cookie-toggle-info p  { font-size: 13px; color: #64748b; margin: 0; line-height: 1.5; }
.cookie-switch {
  position: relative;
  width: 44px; height: 24px;
  flex-shrink: 0;
}
.cookie-switch input { opacity: 0; width: 0; height: 0; }
.cookie-switch-slider {
  position: absolute; inset: 0;
  background: #cbd5e1;
  border-radius: 12px;
  cursor: pointer;
  transition: 0.3s;
}
.cookie-switch-slider::before {
  content: '';
  position: absolute;
  width: 18px; height: 18px;
  left: 3px; bottom: 3px;
  background: #fff;
  border-radius: 50%;
  transition: 0.3s;
}
.cookie-switch input:checked + .cookie-switch-slider { background: #1a56db; }
.cookie-switch input:checked + .cookie-switch-slider::before { transform: translateX(20px); }
.cookie-switch input:disabled + .cookie-switch-slider { opacity: 0.5; cursor: not-allowed; }

.cookie-modal-actions {
  display: flex; gap: 10px; margin-top: 24px; flex-wrap: wrap;
}
.cookie-modal-actions .cookie-btn { flex: 1; text-align: center; }

@media (max-width: 640px) {
  .cookie-banner-inner { flex-direction: column; align-items: flex-start; gap: 14px; }
  .cookie-actions { width: 100%; }
  .cookie-btn { flex: 1; text-align: center; }
  .cookie-btn-custom { width: 100%; }
}
