/* ============================================================
 * ÇEREZ (KVKK/GDPR) BARI + TERCİH MODALI
 * goyayinlari.local'den port; renk token'ları QRKomi'ye uyarlandı
 * (--qr-primary/--qr-dark/--qr-muted/--qr-bg — bkz. style-main.css :root).
 * Tema'da dark-mode ([data-theme]) yok — buraya da eklenmedi.
 * cerez.php ile birebir eşleşir: private/page/tema/core/cerez.php
 * ============================================================ */

.cerez-bar {
    position: fixed; left: 0; right: 0; bottom: 0;
    z-index: 1032; /* .bottom-nav (mobil alt nav) z-index:1030'un bir üstü */
    background: var(--qr-dark);
    color: #f3f4f6;
    box-shadow: 0 -6px 28px rgba(2, 6, 23, 0.22);
    transform: translateY(0);
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.45s ease;
}
.cerez-bar--gizli { transform: translateY(110%); opacity: 0; pointer-events: none; }
.cerez-bar__inner {
    max-width: 1240px; margin: 0 auto;
    padding: 0.7rem 1.5rem;
    display: flex; align-items: center; flex-wrap: nowrap; gap: 1.25rem;
}
.cerez-bar__metin {
    margin: 0; font-size: 0.875rem; line-height: 1.5;
    display: flex; align-items: center; gap: 0.7rem;
    flex: 1 1 auto; min-width: 0;
}
.cerez-bar__metin > i { color: var(--qr-primary); font-size: 1.35rem; flex: none; }
.cerez-bar__metin > span { min-width: 0; }
.cerez-bar__link { color: #fff; text-decoration: underline; text-underline-offset: 2px; white-space: nowrap; }
.cerez-bar__link:hover { color: var(--qr-primary); }
.cerez-bar__aksiyon { display: flex; align-items: center; gap: 0.5rem; flex: none; }

/* Ortak buton stilleri (bar + modal) */
.cerez-btn {
    border: 0; border-radius: 9px; cursor: pointer; white-space: nowrap;
    font-weight: 600; font-size: 0.85rem;
    padding: 0.5rem 1.15rem;
    transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.15s;
}
.cerez-btn--kabul { background: var(--qr-primary); color: #fff; box-shadow: 0 4px 14px rgba(255, 0, 51, 0.32); }
.cerez-btn--kabul:hover { background: var(--qr-primary-hover); transform: translateY(-1px); }
.cerez-btn--reddet { background: transparent; color: #e7e7ea; border: 1px solid rgba(255, 255, 255, 0.3); }
.cerez-btn--reddet:hover { border-color: #fff; background: rgba(255, 255, 255, 0.06); }
.cerez-btn--ayar { background: transparent; color: #b9b9c2; padding-inline: 0.5rem; text-decoration: underline; text-underline-offset: 3px; }
.cerez-btn--ayar:hover { color: #fff; }

/* Tercih modalı */
.cerez-modal { position: fixed; inset: 0; z-index: 1060; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.cerez-modal[hidden] { display: none; }
.cerez-modal__arka { position: absolute; inset: 0; background: rgba(2, 6, 23, 0.55); backdrop-filter: blur(2px); }
.cerez-modal__kutu {
    position: relative; width: 100%; max-width: 560px; max-height: 88vh; overflow-y: auto;
    background: #ffffff; border-radius: 16px; box-shadow: 0 24px 70px rgba(2, 6, 23, 0.35);
    animation: cerezModalAc 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes cerezModalAc { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.cerez-modal__ust { display: flex; align-items: center; justify-content: space-between; padding: 1.2rem 1.5rem; border-bottom: 1px solid rgba(2, 6, 23, 0.1); }
.cerez-modal__x { background: transparent; border: 0; color: var(--qr-muted); font-size: 1.1rem; cursor: pointer; padding: 0.3rem; line-height: 1; }
.cerez-modal__x:hover { color: var(--qr-primary); }
.cerez-modal__govde { padding: 1.3rem 1.5rem; }
.cerez-modal__giris { font-size: 0.88rem; color: var(--qr-muted); line-height: 1.7; margin: 0 0 1.2rem; }
.cerez-modal__giris .cerez-bar__link { color: var(--qr-primary-hover); white-space: normal; }
.cerez-modal__logo { height: 34px; width: auto; display: block; }

/* Modal sekmeleri (Ayarlar / Çerez Politikası) */
.cerez-sekmeler { display: flex; gap: 1.4rem; padding: 0 1.5rem; border-bottom: 1px solid rgba(2, 6, 23, 0.1); }
.cerez-sekme { background: none; border: 0; cursor: pointer; padding: 0.85rem 0; font-weight: 700; font-size: 0.9rem; color: var(--qr-muted); border-bottom: 2px solid transparent; margin-bottom: -1px; transition: color 0.2s, border-color 0.2s; }
.cerez-sekme:hover { color: var(--qr-primary-hover); }
.cerez-sekme--aktif { color: var(--qr-primary-hover); border-bottom-color: var(--qr-primary); }
.cerez-sekme-panel { display: none; }
.cerez-sekme-panel--aktif { display: block; }

/* Uyumluluk rozetleri (Çerez Politikası sekmesi — KVKK / GDPR / Consent Mode v2) */
.cerez-uyum { margin-top: 1.2rem; padding-top: 1rem; border-top: 1px solid rgba(2, 6, 23, 0.1); }
.cerez-uyum-baslik { font-size: 0.92rem; font-weight: 700; color: var(--qr-dark); margin: 0 0 0.6rem; }
.cerez-uyum-kart { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.7rem 0; }
.cerez-uyum-kart + .cerez-uyum-kart { border-top: 1px solid rgba(2, 6, 23, 0.06); }
.cerez-uyum-ikon { flex: none; width: 38px; height: 38px; border-radius: 10px; display: flex; align-items: center; justify-content: center; background: rgba(255, 0, 51, 0.1); color: var(--qr-primary-hover); font-size: 1rem; }
.cerez-uyum-metin strong { display: block; font-size: 0.87rem; color: var(--qr-dark); font-weight: 700; margin-bottom: 0.12rem; }
.cerez-uyum-metin span { font-size: 0.79rem; color: var(--qr-muted); line-height: 1.5; }

/* Akordeon kategori */
.cerez-kat { padding: 0; border-top: 1px solid rgba(2, 6, 23, 0.06); }
.cerez-kat:first-child { border-top: 0; }
.cerez-kat__bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.9rem 0; }
.cerez-kat__ac { flex: 1 1 auto; display: flex; align-items: center; gap: 0.6rem; background: none; border: 0; cursor: pointer; padding: 0; text-align: left; min-width: 0; }
.cerez-kat__ac strong { font-size: 0.95rem; color: var(--qr-dark); font-weight: 700; }
.cerez-kat__ok { color: #9a9a9a; font-size: 0.72rem; transition: transform 0.25s ease, color 0.2s; flex: none; }
.cerez-kat--acik .cerez-kat__ok { transform: rotate(90deg); color: var(--qr-primary); }
.cerez-kat__hep { flex: none; font-size: 0.76rem; font-weight: 700; color: var(--qr-primary-hover); background: rgba(255, 0, 51, 0.1); padding: 0.25rem 0.7rem; border-radius: 50px; }
.cerez-kat__aciklama { display: none; font-size: 0.83rem; color: var(--qr-muted); line-height: 1.6; padding: 0 0 0.9rem 1.35rem; }
.cerez-kat--acik .cerez-kat__aciklama { display: block; animation: cerezKatAc 0.25s ease; }
@keyframes cerezKatAc { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

/* Sol-alt yüzen çerez tercih ikonu (rıza sonrası görünür) */
.cerez-fab {
    /* .scroll-top-btn (style-main.css) ile AYNA hizalama: mobil bottom 90px / 46px,
       masaüstü (>=768) bottom 24px / 50px — sol-alt vs sağ-alt simetrik. */
    position: fixed; left: 18px; bottom: 90px; z-index: 1032;
    width: 46px; height: 46px; border-radius: 50%;
    background: #ffffff; color: var(--qr-primary-hover);
    border: 1px solid rgba(2, 6, 23, 0.1);
    box-shadow: 0 8px 25px rgba(2, 6, 23, 0.16);
    font-size: 1.5rem; cursor: pointer;
    display: none; align-items: center; justify-content: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, color 0.25s ease;
}
.cerez-fab--gorunur { display: flex; }
.cerez-fab:hover { transform: translateY(-3px) rotate(-8deg); box-shadow: 0 10px 28px rgba(255, 0, 51, 0.35); background: var(--qr-primary); color: #fff; }
@media (min-width: 768px) {
    .cerez-fab { left: 24px; bottom: 24px; width: 50px; height: 50px; }
}

.cerez-modal__alt { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: flex-end; padding: 1.1rem 1.5rem; border-top: 1px solid rgba(2, 6, 23, 0.1); background: var(--qr-bg); border-radius: 0 0 16px 16px; }
.cerez-modal__alt .cerez-btn--reddet { color: var(--qr-muted); border-color: rgba(2, 6, 23, 0.18); }
.cerez-modal__alt .cerez-btn--reddet:hover { border-color: var(--qr-muted); background: rgba(2, 6, 23, 0.04); }
.cerez-modal__alt .cerez-btn--ayar { color: var(--qr-primary-hover); }
.cerez-modal__alt .cerez-btn--ayar:hover { color: var(--qr-dark); }

/* Toggle switch */
.cerez-switch { position: relative; flex: none; width: 46px; height: 26px; cursor: pointer; }
.cerez-switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.cerez-switch__yuva { position: absolute; inset: 0; background: rgba(2, 6, 23, 0.22); border-radius: 999px; transition: background 0.2s; }
.cerez-switch__yuva::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; background: #fff; border-radius: 50%; box-shadow: 0 1px 3px rgba(2, 6, 23, 0.25); transition: transform 0.2s; }
.cerez-switch input:checked + .cerez-switch__yuva { background: var(--qr-primary); }
.cerez-switch input:checked + .cerez-switch__yuva::after { transform: translateX(20px); }

/* Mobil alt navigasyon (.bottom-nav, d-md-none) çakışmasın diye bar/fab yukarı kaydırılır
   (bkz. style-main.css .content-wrapper{padding-bottom:68px} — aynı yükseklik referansı). */
@media (max-width: 767.98px) {
    .cerez-bar { bottom: 68px; }
    .cerez-fab { bottom: 90px; } /* .scroll-top-btn mobil bottom ile aynı (bottom-nav 68px'i de aşar) */
}

@media (max-width: 860px) {
    .cerez-bar__inner { flex-wrap: wrap; padding: 0.85rem 1.1rem; gap: 0.75rem; }
    .cerez-bar__metin { flex: 1 1 100%; }
    .cerez-bar__aksiyon { flex: 1 1 100%; justify-content: flex-end; }
}
@media (max-width: 520px) {
    .cerez-bar__aksiyon { flex-wrap: wrap; }
    .cerez-bar__aksiyon .cerez-btn--reddet, .cerez-bar__aksiyon .cerez-btn--kabul { flex: 1 1 auto; text-align: center; }
    .cerez-modal__alt { justify-content: stretch; }
    .cerez-modal__alt .cerez-btn { flex: 1 1 auto; text-align: center; }
}
@media (prefers-reduced-motion: reduce) { .cerez-bar, .cerez-modal__kutu { transition: none; animation: none; } }
