/* cookie-consent.css — Cookie Consent Banner Styles (GDPR / Google Consent Mode v2) */

/* ── Banner container ── */
#tpCookieConsent {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 99999;
  transform: translateY(100%);
  transition: transform .4s cubic-bezier(.4,0,.2,1);
  pointer-events: none;
}
#tpCookieConsent.tpc-visible {
  transform: translateY(0);
  pointer-events: auto;
}

/* ── Glass backdrop ── */
.tpc-backdrop {
  background: rgba(10, 14, 30, .92);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  border-top: 1px solid rgba(54, 209, 255, .12);
  box-shadow: 0 -8px 40px rgba(0, 0, 0, .4);
}
[data-theme="day"] .tpc-backdrop {
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  border-top: 1px solid rgba(0, 0, 0, .08);
  box-shadow: 0 -4px 24px rgba(0, 0, 0, .08);
}

/* ── Inner layout ── */
.tpc-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

/* ── Icon ── */
.tpc-icon {
  flex-shrink: 0;
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(8, 145, 178, .12);
  border-radius: 12px;
  font-size: 1.3rem;
  color: var(--tp-accent, #0891b2);
}
[data-theme="day"] .tpc-icon {
  background: rgba(8, 145, 178, .08);
}

/* ── Text ── */
.tpc-text {
  flex: 1;
  font-size: .84rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, .8);
  min-width: 0;
}
[data-theme="day"] .tpc-text {
  color: #475569;
}
.tpc-text a {
  color: var(--tp-accent, #0891b2);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.tpc-text a:hover {
  color: #36d1ff;
}
[data-theme="day"] .tpc-text a:hover {
  color: #0e7490;
}

/* ── Buttons group ── */
.tpc-btns {
  flex-shrink: 0;
  display: flex;
  gap: .5rem;
  align-items: center;
}

/* ── Shared button base ── */
.tpc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .35rem;
  padding: .5rem 1.1rem;
  border-radius: 8px;
  font-size: .82rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: all .2s ease;
  line-height: 1.3;
}

/* Accept button — accent gradient */
.tpc-accept {
  background: linear-gradient(135deg, #0891b2, #0ea5e9);
  color: #fff;
  box-shadow: 0 2px 8px rgba(8, 145, 178, .25);
}
.tpc-accept:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(8, 145, 178, .35);
}

/* Deny button — subtle outline */
.tpc-deny {
  background: transparent;
  color: rgba(255, 255, 255, .65);
  border: 1px solid rgba(255, 255, 255, .15);
}
.tpc-deny:hover {
  background: rgba(255, 255, 255, .06);
  color: rgba(255, 255, 255, .85);
  border-color: rgba(255, 255, 255, .25);
}
[data-theme="day"] .tpc-deny {
  color: #64748b;
  border-color: rgba(0, 0, 0, .15);
}
[data-theme="day"] .tpc-deny:hover {
  background: rgba(0, 0, 0, .04);
  color: #334155;
  border-color: rgba(0, 0, 0, .25);
}

/* Settings button — ghost / text style */
.tpc-settings {
  background: transparent;
  color: rgba(255, 255, 255, .5);
  padding: .5rem .7rem;
  font-size: .78rem;
}
.tpc-settings:hover {
  color: var(--tp-accent, #0891b2);
}
[data-theme="day"] .tpc-settings {
  color: #94a3b8;
}
[data-theme="day"] .tpc-settings:hover {
  color: var(--tp-accent, #0891b2);
}

/* ── Expanded detail panel ── */
.tpc-detail {
  display: none;
  padding: .75rem 1.25rem 1rem;
  max-width: 1200px;
  margin: 0 auto;
  border-top: 1px solid rgba(255, 255, 255, .06);
}
[data-theme="day"] .tpc-detail {
  border-top-color: rgba(0, 0, 0, .06);
}
.tpc-detail.tpc-detail-open {
  display: block;
}
.tpc-detail-title {
  font-size: .78rem;
  font-weight: 700;
  color: rgba(255, 255, 255, .6);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: .6rem;
}
[data-theme="day"] .tpc-detail-title {
  color: #64748b;
}

/* Cookie category rows */
.tpc-cat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .45rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, .04);
}
[data-theme="day"] .tpc-cat {
  border-bottom-color: rgba(0, 0, 0, .04);
}
.tpc-cat:last-child { border-bottom: 0; }
.tpc-cat-info {
  flex: 1; min-width: 0;
}
.tpc-cat-name {
  font-size: .82rem;
  font-weight: 600;
  color: rgba(255, 255, 255, .85);
}
[data-theme="day"] .tpc-cat-name {
  color: #1e293b;
}
.tpc-cat-desc {
  font-size: .75rem;
  color: rgba(255, 255, 255, .45);
  margin-top: .1rem;
}
[data-theme="day"] .tpc-cat-desc {
  color: #94a3b8;
}

/* Toggle switches */
.tpc-toggle {
  position: relative;
  width: 36px; height: 20px;
  flex-shrink: 0;
  margin-left: 1rem;
}
.tpc-toggle input {
  position: absolute; opacity: 0; width: 0; height: 0;
}
.tpc-toggle-track {
  display: block;
  width: 100%; height: 100%;
  background: rgba(255, 255, 255, .12);
  border-radius: 10px;
  cursor: pointer;
  transition: background .2s;
}
[data-theme="day"] .tpc-toggle-track {
  background: rgba(0, 0, 0, .12);
}
.tpc-toggle-track::after {
  content: '';
  position: absolute;
  top: 2px; left: 2px;
  width: 16px; height: 16px;
  background: #fff;
  border-radius: 50%;
  transition: transform .2s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .2);
}
.tpc-toggle input:checked + .tpc-toggle-track {
  background: var(--tp-accent, #0891b2);
}
.tpc-toggle input:checked + .tpc-toggle-track::after {
  transform: translateX(16px);
}
.tpc-toggle input:disabled + .tpc-toggle-track {
  opacity: .5;
  cursor: not-allowed;
}

/* Save preferences button (inside detail panel) */
.tpc-save {
  margin-top: .75rem;
  background: linear-gradient(135deg, #0891b2, #0ea5e9);
  color: #fff;
  padding: .45rem 1.2rem;
  border-radius: 8px;
  font-size: .8rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all .2s;
}
.tpc-save:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(8, 145, 178, .3);
}

/* ── Responsive ── */
@media (max-width: 767px) {
  .tpc-inner {
    flex-direction: column;
    text-align: center;
    padding: .9rem 1rem;
    gap: .75rem;
  }
  .tpc-icon { display: none; }
  .tpc-btns {
    width: 100%;
    justify-content: center;
  }
  .tpc-detail {
    padding: .6rem 1rem .75rem;
  }
}
@media (max-width: 400px) {
  .tpc-btn {
    padding: .45rem .8rem;
    font-size: .78rem;
  }
}
