/*
 * Cookie Banner Styles for House Of Viyara
 * Follows existing theme: white background, black 4px borders, yellow/cyan accents, neo-brutalism
 */

:root {
  --accent-yellow: #FFD100;
  --accent-cyan: #00D8FF;
  --primary-color: #000000;
  --text-color: #000000;
  --card-bg: #FFFFFF;
  --shadow-color: rgba(0, 0, 0, 0.15);
}

/* Cookie Banner Base Styles */
.cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(150%);
  width: 95%;
  max-width: 900px;
  background: var(--card-bg);
  border: 4px solid var(--primary-color);
  border-radius: 12px;
  box-shadow: 10px 10px 0px var(--primary-color), 0 20px 40px var(--shadow-color);
  padding: 30px;
  z-index: 10000;
  font-family: 'Outfit', sans-serif;
  transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cookie-banner.show {
  transform: translateX(-50%) translateY(0);
}

.cookie-banner.hide {
  transform: translateX(-50%) translateY(150%);
  opacity: 0;
  transition: transform 0.4s ease-out, opacity 0.4s ease-out;
}

.cookie-banner-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.cookie-banner h2 {
  font-size: 2rem;
  font-weight: 900;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.cookie-banner p {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.6;
  margin: 0;
  color: var(--text-color);
}

.cookie-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 10px;
}

/* Cookie Banner Buttons */
.cookie-btn {
  padding: 14px 28px;
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 900;
  border: 4px solid var(--primary-color);
  border-radius: 0;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.cookie-btn-primary {
  background: var(--accent-yellow);
  color: var(--primary-color);
}

.cookie-btn-secondary {
  background: var(--card-bg);
  color: var(--primary-color);
}

.cookie-btn-text {
  background: transparent;
  border: none;
  padding: 0;
  font-weight: 800;
  text-decoration: underline;
  color: var(--primary-color);
  cursor: pointer;
}

.cookie-btn:hover {
  transform: translateY(-3px);
  box-shadow: 6px 6px 0px var(--primary-color);
}

.cookie-btn:active {
  transform: translateY(0);
  box-shadow: 0 0 0px var(--primary-color);
}

/* Ripple Effect */
.cookie-btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.cookie-btn:active::after {
  width: 300px;
  height: 300px;
}

/* Cookie Settings Modal */
.cookie-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10001;
  padding: 20px;
}

.cookie-modal-overlay.show {
  display: flex;
}

.cookie-modal {
  background: var(--card-bg);
  border: 4px solid var(--primary-color);
  border-radius: 12px;
  box-shadow: 10px 10px 0px var(--primary-color), 0 20px 40px var(--shadow-color);
  width: 100%;
  max-width: 700px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 30px;
  transform: scale(0.9);
  opacity: 0;
  transition: transform 0.3s ease-out, opacity 0.3s ease-out;
}

.cookie-modal-overlay.show .cookie-modal {
  transform: scale(1);
  opacity: 1;
}

.cookie-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  border-bottom: 4px solid var(--primary-color);
  padding-bottom: 20px;
}

.cookie-modal-header h2 {
  font-size: 2rem;
  font-weight: 900;
  margin: 0;
}

.cookie-close-btn {
  background: var(--accent-yellow);
  border: 4px solid var(--primary-color);
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 900;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cookie-close-btn:hover {
  transform: translateY(-3px);
  box-shadow: 4px 4px 0px var(--primary-color);
}

/* Cookie Category Items */
.cookie-category {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
  border-bottom: 2px solid var(--primary-color);
}

.cookie-category:last-of-type {
  border-bottom: none;
}

.cookie-category-info h3 {
  font-size: 1.25rem;
  font-weight: 800;
  margin: 0 0 8px 0;
}

.cookie-category-info p {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0;
  opacity: 0.85;
}

.cookie-category-status {
  font-weight: 800;
  font-size: 0.9rem;
  opacity: 0.7;
}

/* Toggle Switch */
.cookie-toggle {
  position: relative;
  width: 70px;
  height: 36px;
}

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

.cookie-toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #e0e0e0;
  border: 4px solid var(--primary-color);
  transition: 0.4s;
  border-radius: 0;
}

.cookie-toggle-slider:before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 4px;
  bottom: 3px;
  background-color: var(--primary-color);
  transition: 0.4s;
  border-radius: 0;
}

.cookie-toggle input:checked + .cookie-toggle-slider {
  background-color: var(--accent-yellow);
}

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

/* Cookie Modal Actions */
.cookie-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 4px solid var(--primary-color);
}

/* Responsive Design */
@media (max-width: 600px) {
  .cookie-banner {
    bottom: 10px;
    padding: 20px;
    width: 90%;
  }

  .cookie-banner h2 {
    font-size: 1.5rem;
  }

  .cookie-banner p {
    font-size: 0.95rem;
  }

  .cookie-banner-actions {
    flex-direction: column;
    width: 100%;
  }

  .cookie-btn {
    width: 100%;
  }
}

/* Dark Mode Future-Ready */
[data-theme="dark"] {
  --accent-yellow: #FFD100;
  --accent-cyan: #00D8FF;
  --primary-color: #FFFFFF;
  --text-color: #FFFFFF;
  --card-bg: #121212;
  --shadow-color: rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .cookie-banner,
[data-theme="dark"] .cookie-modal {
  box-shadow: 10px 10px 0px var(--primary-color), 0 20px 40px rgba(0,0,0,0.8);
}
