/* ══════════════════════════════════════════════
   COOKIE CONSENT BANNER
   ══════════════════════════════════════════════ */

/* Overlay */
.cookie-overlay {
  position: fixed; inset: 0; z-index: 9998;
  background: rgba(11, 29, 58, 0.5);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  opacity: 0; transition: opacity 0.4s ease;
  pointer-events: none;
}
.cookie-overlay.visible { opacity: 1; pointer-events: all; }

/* Banner */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 9999;
  background: #ffffff;
  box-shadow: 0 -8px 40px rgba(11, 29, 58, 0.15);
  transform: translateY(100%);
  transition: transform 0.5s cubic-bezier(.22, 1, .36, 1);
  font-family: 'DM Sans', system-ui, sans-serif;
}
.cookie-banner.visible { transform: translateY(0); }

.cookie-inner {
  max-width: 1200px; margin: 0 auto;
  padding: 1.75rem clamp(1.25rem, 4vw, 3rem);
}

.cookie-main {
  display: flex; align-items: flex-start; gap: 2rem;
  justify-content: space-between;
}

.cookie-text { flex: 1; max-width: 680px; }

.cookie-text h3 {
  font-family: 'Sora', system-ui, sans-serif;
  font-size: 1.15rem; font-weight: 700;
  color: #0b1d3a; margin-bottom: 0.5rem;
}

.cookie-text p {
  font-size: 0.9rem; color: #6b839e; line-height: 1.65; margin: 0;
}
.cookie-text a {
  color: #1a6fb5; text-decoration: underline;
  text-underline-offset: 2px; transition: color 0.3s;
}
.cookie-text a:hover { color: #0b1d3a; }

/* Buttons */
.cookie-buttons {
  display: flex; gap: 0.75rem; align-items: center;
  flex-shrink: 0; flex-wrap: wrap;
}

.cookie-btn {
  padding: 0.7rem 1.5rem; border-radius: 8px; font-size: 0.88rem;
  font-weight: 600; cursor: pointer; border: none;
  font-family: 'DM Sans', system-ui, sans-serif;
  transition: all 0.3s cubic-bezier(.22, 1, .36, 1);
  white-space: nowrap;
}

.cookie-btn-accept {
  background: #0b1d3a; color: #ffffff;
}
.cookie-btn-accept:hover {
  background: #1a6fb5; transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(26, 111, 181, 0.3);
}

.cookie-btn-settings {
  background: transparent; color: #0b1d3a;
  border: 1.5px solid rgba(11, 29, 58, 0.15);
}
.cookie-btn-settings:hover {
  border-color: #0b1d3a; transform: translateY(-1px);
}

.cookie-btn-reject {
  background: transparent; color: #6b839e;
  border: 1.5px solid rgba(11, 29, 58, 0.1);
}
.cookie-btn-reject:hover {
  border-color: #6b839e; color: #0b1d3a; transform: translateY(-1px);
}

/* ── Detail / Settings Panel ──────────────── */
.cookie-details {
  max-height: 0; overflow: hidden;
  transition: max-height 0.5s cubic-bezier(.22, 1, .36, 1), margin 0.3s;
  margin-top: 0;
}
.cookie-details.open {
  max-height: 500px; margin-top: 1.25rem;
}

.cookie-detail-inner {
  border-top: 1px solid rgba(11, 29, 58, 0.08);
  padding-top: 1.25rem;
}

.cookie-category {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(11, 29, 58, 0.05);
}
.cookie-category:last-child { border-bottom: none; }

.cookie-cat-info { flex: 1; }
.cookie-cat-info strong {
  font-size: 0.9rem; color: #0b1d3a; display: block;
}
.cookie-cat-info span {
  font-size: 0.8rem; color: #6b839e;
}

/* Toggle Switch */
.cookie-toggle {
  position: relative; width: 44px; height: 24px; flex-shrink: 0; margin-left: 1rem;
}
.cookie-toggle input { opacity: 0; width: 0; height: 0; }
.cookie-toggle-slider {
  position: absolute; inset: 0; border-radius: 24px;
  background: #d1d9e6; cursor: pointer;
  transition: background 0.3s;
}
.cookie-toggle-slider::before {
  content: ''; position: absolute;
  width: 18px; height: 18px; border-radius: 50%;
  background: #fff; left: 3px; top: 3px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
  transition: transform 0.3s;
}
.cookie-toggle input:checked + .cookie-toggle-slider {
  background: #1a6fb5;
}
.cookie-toggle input:checked + .cookie-toggle-slider::before {
  transform: translateX(20px);
}
.cookie-toggle input:disabled + .cookie-toggle-slider {
  opacity: 0.6; cursor: not-allowed;
}

/* Save button in settings */
.cookie-save-row {
  display: flex; justify-content: flex-end; margin-top: 1rem;
}

/* ── Responsive ───────────────────────────── */
@media (max-width: 768px) {
  .cookie-main {
    flex-direction: column; gap: 1.25rem;
  }
  .cookie-buttons {
    width: 100%;
  }
  .cookie-btn {
    flex: 1; min-width: 0; text-align: center;
    padding: 0.65rem 1rem; font-size: 0.82rem;
  }
}

@media (max-width: 480px) {
  .cookie-buttons {
    flex-direction: column;
  }
  .cookie-btn { width: 100%; }
}
